A simple IN would not match if the actual value of the values column is litterally ''produce(grape,orange,pear,apple,lettuce)' and you want to see if any one of ('apple','orange','banana') is in there....
________________________________ From: dryd...@optonline.net [dryd...@optonline.net] Sent: Wednesday, February 17, 2010 11:31 AM To: Cantwell, Bryan Subject: Re: compare column value to anything in a list of values yes, there is... IN SELECT * FROM tbl WHERE col IN ("v1", "v2", "v3") ----- Original Message ----- From: "Cantwell, Bryan" Date: Wednesday, February 17, 2010 12:25 pm Subject: compare column value to anything in a list of values To: "mysql@lists.mysql.com" > Is there a simple function or method to compare a value in a > column to one or more items in a comma separated list? > > select * from table where value > ('apple','orange','banana'); > and say value may = something like > 'produce(grape,orange,pear,apple,lettuce)'-- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: > http://lists.mysql.com/mysql?unsub=dryd...@optonline.net >