Класическият начин е да добавите запетаи отляво и отдясно:
select * from shirts where CONCAT(',', colors, ',') like '%,1,%'
Но find_in_set също работи:
select * from shirts where find_in_set('1',colors) <> 0
Класическият начин е да добавите запетаи отляво и отдясно:
select * from shirts where CONCAT(',', colors, ',') like '%,1,%'
Но find_in_set също работи:
select * from shirts where find_in_set('1',colors) <> 0