The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | May 2017 |
| Last Sign in: | 398 Weeks Ago, 2 Days Ago |
| Questions Answered: | 66690 |
| Tutorials Posted: | 66688 |
MCS,PHD
Argosy University/ Phoniex University/
Nov-2005 - Oct-2011
Professor
Phoniex University
Oct-2001 - Nov-2016
Consider the following relations for a database that keeps track of business trips of salespersons in a sales office:
SALESPERSON(SSN, Name, Start_Year, Dept_No)
TRIP(SSN, From_City, To_City, Departure_Date, Return_Date, Trip_ID)
EXPENSE(Trip_ID, Account#, Amount)
Specify the foreign keys for the above schema, stating any assumptions you make. Then specify the following queries in relational algebra:
a. Give the details (all attributes of TRIP relation) for trips that exceeded $2000 in expenses.
b. Print the SSN of salesman who took trips to ‘Honolulu’.
c. Print the total trip expenses incurred by the salesman with SSN = ‘234-56-7890’.
Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll