Question: Question 2 ( 4 0 points ) Consider a database schema with three relations: Actors _ ( aid:integer, aname:string, age:real, city:string, state:string ) Movies (
Question points
Consider a database schema with three relations:
Actorsaid:integer, aname:string, age:real, city:string, state:string
Movies mid:integer, mname:string, year:integer, studio:string
Playsin aid:integer, mid:integer, character:string
Primary keys are underlined in each relation. Attribute actor id aid uniquely identifies an actor in Actors relation.
As shown, in addition to id every actor has a name aname an age, and a city and a state.
Attribute mid movie uniquely identifies a movie in relation Movies. In addition to id every movie has a name
mname a year year and a studio that produced it studio
Relation Playsin contains information about actors who played in movies. Attribute character contains the name
of the character that the actor, identified by aid played in the movie, identified by mid.
For each of the following, write a relational algebra expression that produces the desired results.
A Find the names of actors who live in MA state.
B Find the names and the ages of actors who are either from 'Boston' or 'New York'.
C Find the names of actors who are younger than and are from 'Los Angeles'.
D Find the names, cities and states of actors who played as character 'Peter Pan'.
E Find the names of the actors who played in a movie named 'Titanic'.
F Find the name of actors who played in some movie in year and did not play in any movie in
G Find the names of the actors who played in movies only in
H Find the names of actors who are older than and played in some movie produced by 'Universal' studio.
I. Find the names of the actors who played in a movie produced by WB studio in and did not play in any
movie produced by 'Universal' in any year
J Find the names of actors who played in movies both in and
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
