where
select e.*,d.dname
on d.deptno=e.deptno;
2 外连接:
select
where e.deptno(+)=d.deptno
这个左连接表示的是,在部门表中有的部门,但是确没有员工,按照正常的隐式连接查询,没有员工的部门应该不显示;
但是在左连接中显示;
select e.*,d.dname
where e.deptno=d.deptno(+);
这个右连接表示,在员工表中,有些员工没有部门,在正常的隐式连接查询中,没有部门的员工应该不显示;
但是右连接中仍然显示没有部门的员工;
+号加在哪边,对方的不应该显示的记录就会显示
<script type="text/javascript" id="wumiiRelatedItems"> </script>