I need to update a column in a database with values from another column of another database.
Here is my query:
UPDATE dbA.tableA as a
SET a.columnA = b.columnB
FROM dbB.tableB as B
WHERE
a.num = b.num
And I get the error:
1064 - 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 'FROM ...
Both databases are in the same server.
How can I solve this?