note that single quotes ARE needed here:
Enter value for job_ttl: 'Manager'
old 3: where job_title = &job_ttl
new 3: where job_title = 'Manager'
SALARY
----------
2975
2850
2450
DO NOT need quotes here:
Enter value for qtd_job_ttl: Manager
old 3: where job_title = '&qtd_job_ttl'
new 3: where job_title = 'Manager'
SALARY
----------
2975
2850
2450
Enter value for oink: oops
Moo oops
looks like HAVE to put a name after an '&'
character:
SP2-0317: expected symbol name is missing
how about this? &
give salaries for those with the desired job_title
(quotes required!):
Enter value for job_ttl: 'Sales'
old 3: where job_title = &job_ttl
new 3: where job_title = 'Sales'
SALARY
----------
1600
1250
1250
1500
give last names for those with the desired job_title
(quotes required!):
Enter value for job_ttl: 'Sales'
old 3: where job_title = &job_ttl
new 3: where job_title = 'Sales'
EMPL_LAST_NAME
---------------
Michaels
Ward
Martin
Turner
needs BOTH join and nesting
I want the manager's name AND the clerk's name
AND the salary for clerk(s) making the
highest salary
MANAGER CLERK SALARY
--------------- --------------- ----------
Raimi Miller 1300
employee last names and salaries of those who work
in Chicago, using subselect:
EMPL_LAST_NAME SALARY
--------------- ----------
Blake 2850
Michaels 1600
Ward 1250
Martin 1250
Turner 1500
James 950
6 rows selected.
employee last names and salaries of those who work
in Chicago, using join:
EMPL_LAST_NAME SALARY
--------------- ----------
Blake 2850
Michaels 1600
Ward 1250
Martin 1250
Turner 1500
James 950
6 rows selected.
dept names and locations of departments that have
at least one employee hired before June 1, 1991,
using nesting:
DEPT_NAME DEPT_LOC
--------------- ---------------
Research Dallas
Sales Chicago
dept names and locations of departments that have
at least one employee hired before June 1, 1991,
using join:
(make sure you understand WHY more rows are projected here)
DEPT_NAME DEPT_LOC
--------------- ---------------
Research Dallas
Research Dallas
Sales Chicago
Sales Chicago
Sales Chicago