Question: Please help with this DBMS crouse assignment, thank you in advance :) Consider the following relational database schema: employee(employee-name, employee-id, street, e-city) works(employee-id, company-id, salary)

Please help with this DBMS crouse assignment, thank you in advance :)

Please help with this DBMS crouse assignment, thank you in advance :)

Consider the following relational database schema: employee(employee-name, employee-id, street, e-city) works(employee-id, company-id,

Consider the following relational database schema: employee(employee-name, employee-id, street, e-city) works(employee-id, company-id, salary) company(company-name, company-id, c-city) manages (employee-id, manager-id) Specify the following queries on this database schema using the relational algebra operators (Projection [T], selection [6], cross product [x], set difference (-), un- ion[U]) 1. Retrieve the name and address of employees who work for First Bank Corporation. 2. Retrieve the name, street address, and city of residence of all employees who work for Thrifty Industries and earn more than $10,000 per year. 3. Retrieve the name of all employees who live in the same city as the company for which they work. 4. Retrieve the name of all employees who live on the same street and in the same city as do their managers. 5. Retrieve the name of all employees who do not work for First Bank Corporation. 6. Retrieve the name of all employees who earn more than every employee of Small Bank Corporation. 7. (Assume that companies may be located in several cities) Retrieve all companies located in every city in which Thrifty Industries is located. 8. For each company, find the average salary of employees working for that company. 9. For each city, find the number of employees who work for at least one company in that city. Consider the following relational database schema: employee(employee-name, employee-id, street, e-city) works(employee-id, company-id, salary) company(company-name, company-id, c-city) manages (employee-id, manager-id) Specify the following queries on this database schema using the relational algebra operators (Projection [T], selection [6], cross product [x], set difference (-), un- ion[U]) 1. Retrieve the name and address of employees who work for First Bank Corporation. 2. Retrieve the name, street address, and city of residence of all employees who work for Thrifty Industries and earn more than $10,000 per year. 3. Retrieve the name of all employees who live in the same city as the company for which they work. 4. Retrieve the name of all employees who live on the same street and in the same city as do their managers. 5. Retrieve the name of all employees who do not work for First Bank Corporation. 6. Retrieve the name of all employees who earn more than every employee of Small Bank Corporation. 7. (Assume that companies may be located in several cities) Retrieve all companies located in every city in which Thrifty Industries is located. 8. For each company, find the average salary of employees working for that company. 9. For each city, find the number of employees who work for at least one company in that city

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!