有没有更快的方法来获取存在table1但不存在的 idtable2并将它们插入table2?
insert into table2 (id)
select id
from table1
where table1.id not in (select id from table2)
有没有更快的方法来获取存在table1但不存在的 idtable2并将它们插入table2?
insert into table2 (id)
select id
from table1
where table1.id not in (select id from table2)