update fromBset tp2 = a.tp2from(select tpname,tp2 from fromA) as awhere tpname = a.tpname
update froma set froma.tp2=fromb.tp2 from formb where froma.tpname=fromb.tpname