I have a query in php that has an offset in it. I want the offset value to be a variable but I am not sure how to do so. This is my query but it comes up as an error.
$query = "SELECT * FROM comments WHERE `commenter_username` IN (" . join(',', $list) . ") OR `Number` IN (" . join(',', $list) . ") ORDER BY `comment_id` DESC LIMIT 1 OFFSET $offsetNumber";
What is wrong with this?