I'm trying to search a value in a mysql table field. using prepared statements.
services: 2,4,5
passed value: 2
$query = "SELECT *
FROM table
WHERE services IN(':array')"
so basically I'm trying to return all rows where 2 is inside the services field. The field itself will have numbers separated by commas. So the services field can look like this: 2,3,6,7,1 or just something like this: 4. Any help is greatly appreciated.