Customer(custNr, name, baseLoc,birthDt, gender)
Property (propId, ownerNm, propType, state, city, locDesc)
Rental(rentalId, (custNr), (propId), startDt, EndDt, totalCost)
Recommendations:
Before starting to write your queries, it is recommended to insert values to the relations mentioned above, for example purposes.
Customer C
Property P
Rentail R
1. (1 pt) Find the propId, ownerNm, and state for properties with a propType equal to TRADITIONAL.
[P.popId, P.ownerNm, P.state] Property[proptype = "TRADITIONNAL"]
2. (1 pt) Find the propId and startDt for properties which the customer named Ava Kashun has a rental.
[P.propId , R.startDt] Customer[name = "Ava Kashun"]
3. (3 pts) Find the property ID and ownerNm of properties in TX (state) which start after "2019-11-03" for the customer named "Perry Scope".
4. (3 pts) Find the customer numbers and names of customers who have a rental start after "2019-11-04" for a property which customer #444 also had a rental. Do not include #444 in your result. Hint: you will have to use one of the relations twice.
5. (3 pt) Find the customer number of customers who have rented all of the properties having a state of "CO".
6. (4 pts) Find the name, gender, and birth date of customers who only rent properties with a state equal to "CO". State whether your answer includes customers that don't have any associated rentals.
7. (4.5 pts) Find the propId and ownerNm for properties which only customer #777 has a rental. State whether your answer includes properties that don't have any associated rentals.
8. (6 pts) Find the names of customers who have rented all the properties which Penny Lane has rented. State whether you included Penny Lane in your answer.
9. (4.5 pts) Find the customer number, names, and birth date for customers who have not ever rented a property with a state equal to "CO". State whether your answer includes customers that don't have any associated rentals.