列出所有部门的职工人数(包括没有职工的部门) ( )。
A. select dept.deptno,dname,count(emp.empno)from emp,dept where emp.deptno=dept.deptnogroup by dept.deptno,dname;
B. select dept.deptno,dname,count(emp.empno)from emp,dept where emp.deptno(+)=dept.deptnogroup by dept.deptno,dname;
C. select dept.deptno,dname,count(emp.empno)from emp,dept where emp.deptno=dept.deptno(+)group by dept.deptno,dname;
D. select dept.deptno,dname,count(emp.empno)from emp,dept where emp.deptno(+)=dept.deptno(+)group by dept.deptno,dname;
列出KING(公司总裁)的所有下属之间的层次关系,但不要显示出JONES及其所有下属( )。
A. select level,ename,empno,mgr from empconnect by prior empno=mgrand ename<>'JONES'start with ename ='KING'
B. select level,ename,empno,mgr from empconnect by prior empno=mgrand ename='JONES'start with ename ='KING'
C. select level,ename,empno,mgr from empconnect by prior empno=mgrand ename<>'JONES'start with ename <>'KING'
D. select level,ename,empno,mgr from empconnect by prior empno=mgrand ename='JONES'start with ename <>'KING'
列出JONES的所有下属员工,但不包括JONES本人( )。
A. select ename from emp connect by prior empno=mgrstart with ename='JONES';
B. select ename from emp where ename<>'JONES'connect by prior empno=mgrstart with ename='JONES';
C. select ename from emp where ename='JONES'connect by prior empno=mgrstart with ename='JONES';
D. select ename from emp where ename='JONES'connect by prior empno=mgrstart with ename<>'JONES';