Wednesday, 3 August 2011

select a field which contain multiple value .....,,,,,,mysql query for searching a field that contain multiple value seprated by comma

id    name    colors
1     kapil     1,2,3
2     mohit    2,1
3     deepak  1,3


select * from shirts where find_in_set('1',colors) <> 0