使用sql语句导入:
set identity_insert 目标表 on insert 目标表(列的列表) --从源表导出 select 列的列表 from 源表 --源表和目标表的列要对应 set identity_insert 目标表 off |
关键在与设置identity_insert
使用sql语句导入:
set identity_insert 目标表 on insert 目标表(列的列表) --从源表导出 select 列的列表 from 源表 --源表和目标表的列要对应 set identity_insert 目标表 off |
转载于:https://www.cnblogs.com/guojin705/archive/2008/04/15/1154757.html