Ali
Ali

Reputation: 267059

MySQL function which takes a set of strings?

There's a mysql function which works like this:

SELECT * FROM myTbl WHERE name ???('bob', 'jane', 'sally')

The above query should return all records where name is bob, jane, or sally. Where it says ??? above is where the function name should be.

Can anyone remind me what that function is called?

Upvotes: 0

Views: 62

Answers (1)

Ionuț G. Stan
Ionuț G. Stan

Reputation: 179119

SELECT * FROM myTbl WHERE name IN ('bob', 'jane', 'sally')

Upvotes: 7

Related Questions