Fe eids of employees who make the highest salary


Consider the following relations containing airline flight information: Flights(flno: integer, from: string, to: string, distance: integer, departs: time, arrives: time) Aircraft(aid: integer, aname: string, cruisingrange: integer) Certified(eid: integer, aid: integer)

Employees(eid: integer, ename: string, salary: integer)

Note that the Employees relation describes pilots and other kinds of employees as well; every pilot is certified for some aircraft (otherwise, he or she would not qualify as a pilot), and only pilots are certified to fly.

Write the following queries in relational algebra, tuple relational calculus, and domain relational calculus. Note that some of these queries may not be expressible in relational algebra (and, therefore, also not expressible in tuple and domain relational calculus)! For such queries, informally explain why they cannot be expressed. (See the exercises at the end of Chapter 5 for additional queries over the airline schema.)

1. Find the eids of pilots certified for some Boeing aircraft.

2. Find the names of pilots certified for some Boeing aircraft.

3. Find the aids of all aircraft that can be used on non-stop flights from Bonn to Madras.
4. Identify the flights that can be piloted by every pilot whose salary is more than $100,000.

5. Find the names of pilots who can operate planes with a range greater than 3,000 miles but are not certified on any Boeing aircraft.

6. Find the eids of employees who make the highest salary.

7. Find the eids of employees who make the second highest salary.

8. Find the eids of employees who are certified for the largest number of aircraft.

9. Find the eids of employees who are certified for exactly three aircraft.

10. Find the total amount paid to employees as salaries.

11. Is there a sequence of flights from Madison to Timbuktu? Each flight in the sequence is required to depart from the city that is the destination of the previous flight; the first flight must leave Madison, the last flight must reach Timbuktu, and there is no restriction on the number of intermediate flights. Your query must determine whether a sequence of flights from Madison to Timbuktu exists for any input Flights relation instance.

Request for Solution File

Ask an Expert for Answer!!
Database Management System: Fe eids of employees who make the highest salary
Reference No:- TGS01243638

Expected delivery within 24 Hours