SQL> @..\scripts\lab1sol.sql SQL> SQL> -- Q1. List the names of the employees whose salary (excluding commisions) SQL> -- is above 10,000. SQL> Name ---------------------------------------------- Abel,Ellen Cambrault,Gerald De Haan,Lex Errazuriz,Alberto Greenberg,Nancy Hartstein,Michael Higgins,Shelley King,Steven Kochhar,Neena Ozer,Lisa Partners,Karen Raphaely,Den Russell,John Vishney,Clara Zlotkey,Eleni 15 rows selected. SQL> SQL> -- Q2. List the names of the employees who have worked for the company for SQL> -- more than 10 years. SQL> Name ---------------------------------------------- Baer,Hermann De Haan,Lex Ernst,Bruce Faviet,Daniel Gietz,William Greenberg,Nancy Higgins,Shelley Hunold,Alexander Kaufling,Payam Khoo,Alexander King,Steven Kochhar,Neena Ladwig,Renske Mavris,Susan Raphaely,Den Whalen,Jennifer 16 rows selected. SQL> SQL> -- Q3. List the names of the employees who are managers, e.g. their job SQL> -- title has the word "Manager" in it. SQL> Name ---------------------------------------------- Cambrault,Gerald Errazuriz,Alberto Fripp,Adam Greenberg,Nancy Hartstein,Michael Higgins,Shelley Kaufling,Payam Mourgos,Kevin Partners,Karen Raphaely,Den Russell,John Vollman,Shanta Weiss,Matthew Zlotkey,Eleni 14 rows selected. SQL> SQL> -- Q4. List the names of the employees who have worked more than one job in SQL> -- the company. SQL> Name ---------------------------------------------- Kochhar,Neena Taylor,Jonathon Whalen,Jennifer SQL> SQL> -- Q5. List the names of the employees whose salary is above the average SQL> -- for their job title. Note that the average salary for a particular SQL> -- job title can be calculated by averaging the min_salary and SQL> -- max_salary listed in the Jobs relation. SQL> Name ---------------------------------------------- Abel,Ellen Baer,Hermann Bernstein,David Bloom,Harrison Bull,Alexis Chen,John Faviet,Daniel Fox,Tayler Fripp,Adam Gietz,William Greene,Danielle Hartstein,Michael Hunold,Alexander Kaufling,Payam King,Janette Ladwig,Renske Ozer,Lisa Popp,Luis Sarchand,Nandita Sciarra,Ismael Sully,Patrick Tucker,Peter Urman,Jose Manuel Vishney,Clara Weiss,Matthew 25 rows selected. SQL> SQL> -- Q6. List the names of the departments that are located in Europe. SQL> DEPARTMENT_NAME ------------------------------ Human Resources Public Relations Sales SQL> SQL> -- Q7. List the names of the departments that have more than 10 employees. SQL> DEPARTMENT_NAME ------------------------------ Sales Shipping SQL> SQL> -- Q8. List the names of the top 3 departments that have the highest SQL> -- average employee salary. SQL> DEPARTMENT_NAME ------------------------------ Executive Accounting Public Relations SQL> SQL> -- Q9. List the average employee salary in each region. Output -1 for a SQL> -- region if there are no employees working in that region. SQL> REGION_NAME Avg Salary ------------------------- ---------- Americas 5191.42857 Asia -1 Europe 8916.66667 Middle East and Africa -1 SQL>