读书人

各位大大们这个有关问题的语句如何写

发布时间: 2013-07-08 14:13:00 作者: rapoo

各位大大们,这个问题的语句怎么写啊
将table1表a字段修改为table2表id字段相同的记录行b字段值

[解决办法]
update table1 set a=table2.b
from table2
where table1.id=table2.id
[解决办法]
update A set a=B.b from
table1 A,table B
where a.id=b.id

读书人网 >SQL Server

热点推荐