Salve a tutti!

come faccio x fare una UPDATE in sql tra 2 tabelle di questo tipo?

codice:
update tab1,tab2 set tab1.nome=tab2.nome where tab1.code=tab2.code
thanks!