|
原帖由 凝结水晶 于 2010-7-14 16:40 发表 ![]()
通常我们用的是外关联,例如:
要找到在test1中存在但是test2不存在的记录
select a.*
from test1 a,
test2 b
where a.id=b.id(+)
and b.id is null ;
以上的left连接如果用新语法来改写的话,应该是以下的形式吧??
select a.*
from test1 a left outer join test2 b on a.id = b.id where b.id is null;
这里不因该是from test1 a left outer join test2 b on a.id = b.id and b.id is null;吧?
[ 本帖最后由 ccsnmoracle 于 2010-11-8 06:26 编辑 ] |
|