I have these two tables with the same structure but with different number of datas.
Table First
id INT
type INT
Table Second
id INT
type INT
I need to update the type of the table “FIRST” with the value Type of table “SECOND” and I try to execute this statment
update First set
type = (
select Second.type
from First,
Second
where First.id=Second.id
)
But it doesn’t run.
Where I’ve mistaken?
Thanks for any suggestions.
Your syntax is incorrect. Try instead: