远程数据库中有一800W的数据表a,本地有一20W的数据表b,a,b两表的结构一样,根据b中的主建=a中的主建,update 800w的数据表的其他字段,性能极差,每1000条需要5分多,共大约需18小时,有没有好的方法?
update [x.x.x.x].database.dbo.table_a
set a=y.a,b=y.b,c=y.c
from [x.x.x.x].database.dbo.table_aas x ,table_b as y
where x.id=y.id
[ 本帖最后由 oo4o 于 2007-11-21 13:52 编辑 ]
|