I have a field in my database called "id_nums" which store comma seperated values, such as
I then have a php query which looks like
$sql = "SELECT * FROM products WHERE id = $id";
At the moment is basically is selecting all rows which match the id number, what I want to do is display all row id numbers which match the comma seperated value "id_nums".
So if it passed the value
it would display all the rows with those id numbers
$sql = "SELECT * FROM products WHERE id = $id_nums";
But it doesnt seem to be able to do multiple selecting this way.
Can anyone help?
Thanks in advance