Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

( i ) Figure 1 shows an example relational database about employees working on projects: ( ii ) Construct an SQL statement for the following

(i) Figure 1 shows an example relational database about employees working on projects:
(ii) Construct an SQL statement for the following query: List the name of the project, the number of employees working on the project, and the total employee cost (HourRate * TotalHours) on the project for those projects that have involved employees. What would be the result table that the SQL statement produces?
(iii) Describe the following queries using the Relational Algebra:
a. List the names of the projects with no employees working on them;
b. List pairs of names for employees working on the same projects.
(iv) This part of the question is about referential integrity constraint.
a. If the DBA wants to enforce the referential integrity constraint on the existing tables in
b. If the enforcement action is NO ACTION, what would happen if there is an attempt to remove the row about BlueSea project from the Projects table?
c. If the employees are permanent where they work on different projects from time to time, what would be the most sensible enforcement action to take when a specific project record is removed? If the employees are only contracted to work on specific projects, what would be the most sensible enforcement action to take when the specific project records are removed? Justify your answer.
image text in transcribed

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

Data Access Patterns Database Interactions In Object Oriented Applications

Authors: Clifton Nock

1st Edition

0321555627, 978-0321555625

More Books

Students also viewed these Databases questions

Question

10. Describe the relationship between communication and power.

Answered: 1 week ago