I have a table filled with ID numbers, which I need to loop through, and use as variables in a prepared statement. I do not know if I need to use a stored procedure for this, o
Use a simple query like:
SELECT * FROM data WHERE id IN ( SELECT id FROM var_list )