Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Exercise 1: Specify the following queries on the COMPANY (Lab#1) relational database schema, using the relational operators. Also show the result of each query as

image text in transcribed
image text in transcribed
Exercise 1: Specify the following queries on the COMPANY (Lab\#1) relational database schema, using the relational operators. Also show the result of each query as it would apply to the database state + Write them in Relational Algebra. j) Retrieve the names of employees in department 5 who work more than 10 hours per week on the 'ProductX' project. k) )b) List the names of employees who have a dependent with the same first name as themselves. I) Find the names of employees that are directly supervised by 'Franklin Wong.' m ) For each project, list the project name and the total hours per week (by all employees) spent on that project. n) Retrieve the names of employees who work on every project. o) Retrieve the names of employees who do not work on any project. p) For each department, retrieve the department name, and the average salary of employees working in that department. q) Retrieve the average salary of all female employees. r) Find the names and addresses of employees who work on at least one project located in Houston but whose department has no location in Houston. s) List the last names of department managers who have no dependents Consider the LIBRARY relational schema shown in Figure 6.14, which is used to keep track of books, borrowers, and book loans. Referential integrity constraints are shown as directed arcs in Figure 6.14, Write down Relational Algebra for the following queries on the LIBRARY database: h) How many copies of the book titled The Lost Tribe are owned by the library branch whose name is "Sharpstown?" i) Retrieve the names of all borrowers who do not have any books checked out.. j) Retrieve the names, addresses, and number of books checked out for all borrowers who have more than five books checked out. k) How many copies of the book titled The Lost Tribe are owned by each library branch

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

Database Concepts

Authors: David Kroenke, David Auer, Scott Vandenberg, Robert Yoder

10th Edition

0137916787, 978-0137916788

More Books

Students also viewed these Databases questions