SELECT last_name, department_name, location_id FROM employees , department ;
SELECT employees.last_name, departments.department_name, departments.location_id FROM employees e, departments D WHERE e.department_id = d.department_id;
SELECT e.last_name, d.department_name, d.location_id FROM employees e, departments D WHERE manager_id = manager_id;
SELECT e.last_name, d.department_name, d.location_id FROM employees e, departments D WHERE e.department_id = d.department_id;
第1题:
A.
B.
C.
D.
第2题:
Examine the data from the EMP table:The COMMISSION column shows the monthly commission earned by the employee.Which three tasks would require subqueries or joins in order to perform in a single step?()
A. Deleting the records of employees who do not earn commission.
B. Increasing the commission of employee 3 by the average commission earned in department 20.
C. Finding the number of employees who do NOT earn commission and are working for department 20.
D. Inserting into the table a new employee 10 who works for department 20 and earns a commission that is equal to the commission earned by employee 3.
E. Creating a table called COMMISSION that has the same structure and data as the columns EMP_ID and COMMISSIONS of the EMP table.
F. Decreasing the commission by 150 for the employees who are working in department 30 and earning a commission of more then 800.
第3题:
A. To find the tax percentage for each of the employees.
B. To list the name, job id, and manager name for all the employees.
C. To find the name, salary, and department name of employees who are not working with Smith.
D. To find the number of employees working for the Administrative department and earning less then 4000.
E. To display name, salary, manager ID, and department name of all the employees, even if the employees do not have a department ID assigned.
第4题:
A.
B.
C.
D.
第5题:
A.
B.
C.
D.
第6题:
A. You have no rows in the table.
B. You have an employee with the name of James.
C. You cannot roll back to the same savepoint more than once.
D. Your last update fails to update any rows because employee ID 180 was already eleted.
第7题:
A.
B.
C.
D.
第8题:
Examine the structure of the EMPLOYEES table:You need to update the records of employees 103 and 115. The UPDATE statement you specify should update the rows with the values specified below:Which UPDATE statement meets the requirements?()
A.
B.
C.
D.
E.
第9题:
A.
B.
C.
D.
第10题:
Examine the data in the EMPLOYEES and DEPARTMENTS tables:Also examine the SQL statements that create the EMPLOYEES and DEPARTMENTS tables:On the EMPLOYEES table, EMPLOYEE_ID is the primary key.MGR_ID is the ID of managers and refers to the EMPLOYEE_ID.DEPT_ID is foreign key to DEPARTMENT_ID column of the DEPARTMENTS table.On the DEPARTMENTS table, DEPARTMENT_ID is the primary key.Examine this DELETE statement:What happens when you execute the DELETE statement?()
A. Only the row with department ID 40 is deleted in the DEPARTMENTS table.
B. The statement fails because there are child records in the EMPLOYEES table with department ID 40.
C. The row with department ID 40 is deleted in the DEPARTMENTS table. Also the rows with employee IDs 110 and 106 are deleted from the EMPLOYEES table.
D. The row with department ID 40 is deleted in the DEPARTMENTS table. Also the rows with employee IDs 106 and 110 and the employees working under employee 110 are deleted from the EMPLOYEES table.
E. The row with department ID 40 is deleted in the DEPARTMENTS table. Also all the rows in the EMPLOYEES table are deleted.
F. The statement fails because there are no columns specifies in the DELETE clause of the DELETE statement.