Computer Science Homework Solutions
Problem
#78948

Relational Algebra Expressions

Cannot use SQL - much show expression

Tables in a relational database:
Hotel (hotelNo, hotelName, city)
Room (roomNo, hotelNo, type, price)
Booking                 (hotelNo, guestNo, dateFrom, dateTo, roomNo)
Guest (guestNo, guestName, guestAddress)

A)  Need to generate the relational algebra expression for the following queries:

1 List all hotels
2 List all single rooms with a price below $50 per night
3 List the names and cities of all guests
4 List the price and type of all rooms at the ABC Hotel
5 List all guests currently staying at the ABC Hotel
6 List the details of all rooms at the ABC Hotel, including the name of        the guest staying in the room, if the room is occupied
7 List the guest details (guestNo, guestName, and guestAddress) of all guests staying at the ABC Hotel.

B)  Using Relational algebra, create a view of all rooms in the ABC Hotel, excluding price details.  

Solution
What is this?
By OTA - Overall OTA Rating
Xiao Liu, MS - 4.7/5
Purchase Cost Now
$2.19 CAD (was ~$27.93)
Included in Download
  • Plain text response
  • Attached file(s):
    • Scan0001.jpg
    • relationalAgebra_view.doc
$2.19 Instant Download
Add to Cart
Why you can trust BrainMass.com
  • Your Information is Secure
  • Best Online Academic Help Service
  • Students find real academic Success
Related Solutions
Browse