Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In this tutorial, your task is to implement the SQL solutions for the given query below. The queries are based on the Company database that

image text in transcribed
image text in transcribed
image text in transcribed
In this tutorial, your task is to implement the SQL solutions for the given query below. The queries are based on the Company database that was used in the fecture. Build the Company DB by using the three SQL files available on the course web site on the appropriate week in the same way you built the DB in previous tutorials. The first file "BldCmpnyDB" which builds the relation DB schema and "PopltCmpnyDB" file populates the tables with data, and the last file, "SetLnkCmpnyDB" sets all the links between tables. The diagram below represent the logical data model for the Company DB and shows the links between tables. Primary keys are underlined. 3. For the following network diagram: a) Perform a Forward Pass and a Backward Pass b) Determine the critical path(s) C) Draw the Gantt Chart 1. Retrieve the name and address of all employees who work for the 'Research' department. 2. For every project located in 'Stafford', list the project number, the controlling department number, and the department manager's last name, address, and birth date. 3. For each employee, retrieve the employee's name, and the name of his or her immediate supervisor. 4. Retrieve the name and address for every employee in the accounting department. 5. Retrieve the name of each employee who has a dependent with the same first name as the employee. 6. Retrieve the names of employees who have no dependents. 7. Retrieve the names of all employees who do not have supervisors. 8. For each department, retrieve the department number, the number of employees in the department, and their average salary. 9. For each project, retrieve the project number, project name, and the number of employees who work on that project. 10. Show the effect of giving all employees who work on the 'Product X project a 10% raise. Directed Unsupervised Learning- The queries below are for Degree students only. 11. Change the location and controlling department number of project number 10 to 'Bellaire' and 5, respectively. 12. List the names of managers who have at least one dependent 13. For each project on which more than two employees work, retrieve the project number, project name, and the number of employees who work on that project. 14. Give all employees in the 'Research' department a 10% raise in salary. 15. Make a list of all project numbers for projects that involve an employee whose last name is 'Smith' as a worker or as a manager of the department that controls the project. 16. Retrieve the name of each employee who works on all the projects controlled by department number 5 . In this tutorial, your task is to implement the SQL solutions for the given query below. The queries are based on the Company database that was used in the fecture. Build the Company DB by using the three SQL files available on the course web site on the appropriate week in the same way you built the DB in previous tutorials. The first file "BldCmpnyDB" which builds the relation DB schema and "PopltCmpnyDB" file populates the tables with data, and the last file, "SetLnkCmpnyDB" sets all the links between tables. The diagram below represent the logical data model for the Company DB and shows the links between tables. Primary keys are underlined. 3. For the following network diagram: a) Perform a Forward Pass and a Backward Pass b) Determine the critical path(s) C) Draw the Gantt Chart 1. Retrieve the name and address of all employees who work for the 'Research' department. 2. For every project located in 'Stafford', list the project number, the controlling department number, and the department manager's last name, address, and birth date. 3. For each employee, retrieve the employee's name, and the name of his or her immediate supervisor. 4. Retrieve the name and address for every employee in the accounting department. 5. Retrieve the name of each employee who has a dependent with the same first name as the employee. 6. Retrieve the names of employees who have no dependents. 7. Retrieve the names of all employees who do not have supervisors. 8. For each department, retrieve the department number, the number of employees in the department, and their average salary. 9. For each project, retrieve the project number, project name, and the number of employees who work on that project. 10. Show the effect of giving all employees who work on the 'Product X project a 10% raise. Directed Unsupervised Learning- The queries below are for Degree students only. 11. Change the location and controlling department number of project number 10 to 'Bellaire' and 5, respectively. 12. List the names of managers who have at least one dependent 13. For each project on which more than two employees work, retrieve the project number, project name, and the number of employees who work on that project. 14. Give all employees in the 'Research' department a 10% raise in salary. 15. Make a list of all project numbers for projects that involve an employee whose last name is 'Smith' as a worker or as a manager of the department that controls the project. 16. Retrieve the name of each employee who works on all the projects controlled by department number 5

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Financial Accounting

Authors: Jan R. Williams, Susan F. Haka, Mark S. Bettner, Joseph V. Carcello

12th Edition

0071116796, 978-0071116794

More Books

Students also viewed these Accounting questions