Evaluate the SQL statement:1 SELECT a.emp_name, a.sal, a.dept_id, b.maxsal2 FROM employees a,3 (SELECT dept_id, MAX(sal) maxsal4. FROM employees5 GROUP BY dept_id) b6 WHERE a.dept_id = b.dept_id7 AND a. asl < b. maxsal;What is the result of the statement? ()
A. The statement produces an error at line 1.
B. The statement produces an error at line 3.
C. The statement produces an error at line 6.
D. The statement returns the employee name, salary, department ID, and maximum salary earned in the department of the employee for all departments that pay less salary then the maximum salary paid in the company.
E. The statement returns the employee name, salary, department ID, and maximum salary earned in the department of the employee for all employees who earn less than the maximum salary in their department.
第1题:
标准SQL基本查询模块的结构是
A.SELECT. . . FROM. . . ORDER BY
B.SELECT. . . WHERE. . . GROUP BY
C.SELECT. . . WHERE. . . HAVING
D.SELECT. . . FROM. . . WHERE.
第2题:
在SQL查询中,若要取得“学生”数据表中的所有记录和字段,其SQL语法为( )。
A.SELECT姓名FROM学生
B.SELECT*FROM学生
C.SELECT姓名FROM学生WHERE学号=02650
D.SELECT*FROM学生WHERE学号=02650
第3题:
查询“学生”表的所有记录并存储于表文件table1中的SQL语句是( )。
A)SELECT﹡FROM学生INTOCURSORtable1
B)SELECT﹡FROM学生TOCURSORtable1
C)SELECT﹡F1的M学生INTODBFtable1
D)SELECT﹡FROM学生TOTABLEtable1
第4题:
在SQL查询中,若要取得“学生”数据表中的所有记录和字段,其SQL语法为( )。
A.SELECT*FROM学生
B.SELECT姓名FROM学生
C.SELECT姓名FROM学生WHILE学号=02650
D.SELECT*FROM学生WHILE学号=02650
第5题:
标准SQL基本查询模块的结构是______。
A.SELECT…FROM…ORDER BY
B.SELECT…1WHERE…GROUP BY
C.SELECT…WHERE…HAVING
D.SELECT…FROM…WHERE
第6题:
在SQL查询中,若要取得“学生”数据表中的所有记录和字段,其SQL语法为( )。
A)SELECT姓名FROM学生
B)SELECT*FROM学生
C)SELECT姓名FROM学生WHERE学号=02650
D)SELECT*FROM学生WHERE学号=02650