Corporate Tax
Control And Credit
Shareholder Services
Benefits
Manufacturing
Construction
Contracting
Operations
IT Support
NOC
IT Helpdesk
Government Sales
Retail Sales
Recruiting
Payroll
16 rows selected.
select department_name from departments where not exists (
select * from employees where employees.department_id=departments.department_id)
| Id | Operation | Name | Rows | Cost (%CPU) |
|---|---|---|---|---|
| 0 | .SELECT STATEMENT | | 17 | 3 (0) |
| 1 | ..NESTED LOOPS ANTI | | 17 | 3 (0) |
| 2 | ...TABLE ACCESS FULL | DEPARTMENTS | 27 | 3 (0) |
| 3 | ...INDEX RANGE SCAN | EMP_DEPARTMENT_IX | 41 | 0 (0) |
select department_name from departments left join employees using (department_id) where email is null
| Id | .Operation | Name | Rows | Cost (%CPU) |
| 0 | .SELECT.STATEMENT | 106 | 6 (17) | |
| 1 | ..FILTER. | |||
| 2 | ...MERGE.JOIN.OUTER | 106 | 6 (17) | |
| 3 | ....TABLE.ACCESS.BY.INDEX.ROWID | DEPARTMENTS | 27 | 2 (0) |
| 4 | .....INDEX.FULL.SCAN | DEPT_ID_PK | 27 | 1 (0) |
| 5 | ....SORT.JOIN | 107 | 4 (25) | |
| 6 | .....TABLE.ACCESS.FULL | EMPLOYEES | 107 | 3 (0) |
没有评论:
发表评论