Dale Hans <[EMAIL PROTECTED]> wrote: > I have a field in the table, call it 'stuff', and it contains a list > of values that are comma separated. i.e. 'Books,DVDs,Video > Tapes,CDs' > > I want to SELECT out all records that have an item. I know IN works > the other way, so is there something that will get what I want like > this: > > SELECT * FROM Inventory > WHERE stuff CONTAINS 'Books' > ORDER BY name >
Take a look at FIND_IN_SET() function: http://www.mysql.com/doc/en/String_functions.html -- For technical support contracts, goto https://order.mysql.com/?ref=ensita This email is sponsored by Ensita.net http://www.ensita.net/ __ ___ ___ ____ __ / |/ /_ __/ __/ __ \/ / Egor Egorov / /|_/ / // /\ \/ /_/ / /__ [EMAIL PROTECTED] /_/ /_/\_, /___/\___\_\___/ MySQL AB / Ensita.net <___/ www.mysql.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]