Question

Problem 1 Consider the following relations containing airline flight information, where the keys are underlined ghts(no: integer, from: string, to: string, distance: integer, departs: time, arrives: time) aircraftlaid: integer, aname: string, crusingrange: 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. Note that it is possible that some of the queries below may not be expressible in relational algebra. For such queries, informally explain why they cannot be expressed. Write the following queries in relational algebra. (5 points) a) b) Find the names of pilots certified for some Boeing aircraft. Identify the flights that are piloted by every pilot whose salary is more than 100,000. (5 points) (5 points) c) Find the eids of employees who make the highest salary.
0 0
Add a comment Improve this question Transcribed image text
Answer #1

check the solution below in the image . if you have any doubt in any solution , you write in comment box . I will explain you as soon as possible

Thankyouor Some ol sp1 Joh three Jabus gkp Boci Employus) H2 Identity -hiyigah thai ayu pilotul b) evouy Salaxy ii mere than 00,000

Add a comment
Know the answer?
Add Answer to:
Problem 1 Consider the following relations containing airline flight information, where the keys are underlined ghts(no:...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Consider the following relations for an airline company: Flights (flno: integer, from: string, to: string, distance:...

    Consider the following relations for an airline company: Flights (flno: integer, from: string, to: string, distance: integer, departs: time, arrives: time) Aircraft (aid: integer, aname: string, cruising_range: integer) Certifed (pid: integer, aid: integer) Pilots (pid: integer, pname: string, salary: integer) (word in bold are primary keys) Note that every pilot is certified for some aircraft. Write the following queries in relational algebra: 1- Find the flight numbers of flights departing from ‘Amsterdam’ or ‘London’ between 8:00am and 11:00am, and arriving...

  • The following relations keep track of airline flight information: Flight (flno: int, from: varchar(20), to: varchar(20),...

    The following relations keep track of airline flight information: Flight (flno: int, from: varchar(20), to: varchar(20), distance: real, departs: time, arrives: time, price: real) Aircraft (aid: int, aname: varchar(20), cruisingrange: real) Certified (eid: int, aid: int) Employee (eid: int, ename: varchar(20), salary: real) Note that the Employee relation describes pilots and other kinds of employees as well; every pilot is certified for some aircraft, and only pilots are certified to fly. Write each of the following queries in SQL. 1....

  • Find flno of flights that can be piloted by every pilot whose salary is over $100,000...

    Find flno of flights that can be piloted by every pilot whose salary is over $100,000 without using the division operator. Flights (flno, from, to, distance, departs) Aircraft (aid, aname, range) Certified (eid, aid) Employees leid, ename, salary)

  • -Consider the following table definition, where the primary keys are underlined. Give an expression in relational...

    -Consider the following table definition, where the primary keys are underlined. Give an expression in relational algebra for each of the following queries. Athlete (aID integer, aName string, ranking integer, age integer) Event (eID string, eName string, eLocation string) Competes (aID integer, eID string, sport string, year integer) 3. Find the names of the events an athlete named Dennis competed in (aName = ‘Dennis’) 4. Find the names of the athletes who have competed in at least one Event 5....

  • Consider the following table definition, where the primary keys are underlined. Give an expression in relational...

    Consider the following table definition, where the primary keys are underlined. Give an expression in relational algebra for each of the following queries. Athlete (aID integer, aName string, ranking integer, age integer) Event (eID string, eName string, eLocation string) Competes (aID integer, eID string, sport string, year integer) 1. Find the names of athletes who have competed in event 1Sk8P (eiD = ‘1Sk8P’) 2. Find the names of athletes who have competed in the event XGames (eName = ‘XGames’) 3....

  • Consider the database consisting of the following relations: Flights(Fl#: integer, From: string, To: string, Distance: integer,...

    Consider the database consisting of the following relations: Flights(Fl#: integer, From: string, To: string, Distance: integer, departs: Time, Arrives: time) Flight Instance(Fl#: integer, Day: date, Aid: Integer) Aircraft(Aid: integer, Make: string, Model: string, CrusingRange: string) Certified(Eid: integer, Make: string, Model: string) Employee(Eid: integer, Ename: string, Salary: integer) Fight Attendant(Fl#: integer, Day: date, Eid:integer, Role: string) The Flight table contains general information about the flights whereas the Flight Instance is about a flight number on a specific date. Aircraft list the...

  • Any help appreciated! Question 1 (5 points). Answer each of the following questions briefly. The questions...

    Any help appreciated! Question 1 (5 points). Answer each of the following questions briefly. The questions are based on the following relational schema: Emp( eid: integer, ename: string, age: integer, sala1l1: real) Works( eid: integer, did: integer, pet_time: integer) Dept(did: integer, dname: string, budget: real, managerid: integer) 1. Give an example of a foreign key constraint that involves the Dept relation. 2. Write the SQL statements required to create the preceding relations, including appropriate versions of all primary and foreign...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT