【发布时间】:2012-11-06 03:58:02
【问题描述】:
表一:
- 身份证
- 姓名
表2:
- 身份证
- other_table_id
- table_1_id
- ..
基本上我想做的是
Delete from table_1
where id not in (select table_1_id
from table_2
group by table_1_id);
哪个应该起作用,我想知道子查询是否是执行此操作的最佳方法/还有其他方法吗?
【问题讨论】: