我有一张桌子上有人的字段" id" "名称"和" p_father" 我想选择" id"字段不会出现在" p_father"
列中我尝试这个查询
select * from people where (id not in (select p_father from people));
但这并没有向我显示任何结果。但是,如果我使用此查询
select * from people where (id in (select p_father from people));
它显示了我想要选择的所有记录
谢谢!