I got the IDs(the rows to be updated) in this query from post table, with those IDs as rows in grade table, I want to set one var to 1, and others in this array to 0, and keep the rest rows in the grade table unchanged:
SELECT ID FROM posts
WHERE post_parent = ''
AND post_status IN ( '')
AND post_type = ''
I’d like to learn how to update the grade table as described above. Thanks!
You can use this solution: