Already tried that, but is 2 appears at the end of the list is doesn't get picked up because there is no comma at the end of the list
Best regards >>> Andrew Dixon -----Original Message----- From: Dean Urmson [mailto:[EMAIL PROTECTED] Sent: 11 June 2004 12:53 To: [EMAIL PROTECTED] Subject: RE: Query Help > For example: > > gallery_id | gallery_name | keywords > 1 | test | 1,2,3,4 > 2 | test2 | 3,4,5,6 > > And I won't to get all the galleries with where the have the keywords > 2, which in this case would be record 1 or keyword 4 which would be > both record. > > SELECT gallery_id, gallery_name > FROM galleries > WHERE keywords ???? > SELECT gallery_id, gallery_name FROM galleries WHERE keywords LIKE '%2% Or if you want to avoid the above picking up keywords 12, 20, 21, 22 etc... And each keyword is seperated with a comma then SELECT gallery_id, gallery_name FROM galleries WHERE keywords LIKE '%2,% Cheers Dean -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]