Question: 1. Consider a database with the following schema: Person (name, age, gender) name is a key Frequents (name, iceCreamShop) (name, ice cream shop) is a
1. Consider a database with the following schema: Person (name, age, gender) name is a key Frequents (name, iceCreamShop) (name, ice cream shop) is a key Eats (name, flavor) (name, flavor) is a key Sells (iceCreamShop, flavor, price) (iceCreamShop, flavor) is a key Using relational algebra:
e) For each person, find all ice cream flavors the person eats that are not served by any ice cream shop the person frequents. Return the name of the person and the ice cream flavor in pairs.
f) Find an ice cream shop that is frequented by people older than 30 but younger than 40 years old.
g) Find all the names of females that frequent every ice cream shop serving at least one flavor they eat. h) Find the ice cream shop with the most expensive scoop of vanilla ice cream, if theres more than one return all that apply.
i) Find the names of all people who frequent only ice cream shops serving at least one flavor they like
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
