Can anyone help with sample of joining a select query with an update query i tried using UNION and UNION ALL but it keeps telling me to check my syntax Invalid query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'UPDATE pages SET id= this is the query select * from pages where id="206" UNION ALL UPDATE pages SET id="999" where id="164" id column is varchar
I don't think you can do that, and I don't see why you would need to. Your queries don't even seem related, why don't you do seperate ones?
if it is just two unconnected queries then you simply separate them with a ; select * from pages where id="206"; UPDATE pages SET id="999" where id="164"