Addendum to CPS 430/542 Homework #7Assigned: November 29Due: December 6, 4:30pm, in class (10 points) An indulgent pastime in the movie industry is to make `connections' among actors and actresses through the movies they have acted in (together). For example, to make a connection between Tom Hanks and Kevin Bacon, it just takes one step (both acted in `Apollo 13', for instance). However, to make a link from Errol Flynn to Kevin Bacon, it takes two steps (they have to be `routed' through Eddie Albert, because they have not acted in a movie together). So from Flynn, you get to `The Roots of Heaven,' from there you go to Albert, then you take `The Big Picture' to Bacon. A UVA student has mined the Internet Movie Database to create the Oracle of Bacon. Recently, an Amazon.com affiliate has developed The Amazing Baconizer which will attempt to connects two books, DVD's, or CD's within transaction data. Similar procedures exist in the academic world. For example, Erdos number, where people are linked by the publications they co-author. Academicians and researchers then proudly flaunt their Erdos number! Dr. Sri's Erdos number is 2. See the article in the December 1998 issue of Discover magazine for more information on the small-world phenomenon. Okay, back to CPS 430/532. We seek to use database technology to identify connections among stars. Assume that you are given the following tuples in a two-column relation called ActsIn: (Uma Thurman, Mad Dog and Glory) (Robert De Niro, Cape Fear) (Woody Harrelson, Natural Born Killers) (Dan Aykroyd, The Actor) (Judge Reinhold, Beverly Hills Cop) (Jamie Lee Curtis, True Lies) (Woody Harrelson, Palmetto) (Nick Nolte, 48 Hours) (James Russo, Beverly Hills Cop) (Eddie Murphy, 48 Hours) (Jamie Lee Curtis, Perfect) (Tommy Lee Jones, Natural Born Killers) (Dan Aykroyd, North) (Tara King, 48 Hours) (Robert De Niro, Sleepers) (Nick Nolte, Cape Fear) (Juliette Lewis, Natural Born Killers) (Jessica Lange, Cape Fear) (Eddie Murphy, Beverly Hills Cop) (Robert De Niro, Mad Dog and Glory) (Robert Downey Jr., Natural Born Killers) (Eddie Murphy, Trading Places) (Juliette Lewis, Cape Fear) Your task is to make a connection between Woody Harrelson and Eddie Murphy, using only the data shown above. Of course, you realize that we are not really worried about how these two are related (in the totality of real-life data), but to see if you can effect the connection with an SQL query. So, use the diagram below; your goal is to fill in the missing two star names and three movie names. To do that, you need to write an SQL query and run it only on the data shown above (again, we are not interested in `complete and real' data, only the results on the data shown above). For full credit, submit your SQL query and the result that you get. To do this exercise, you need to actually sit in front of the computer, load the data, write the query and report on the answer.
FAQ: Q: I found a `shorter path' between these two actors! Is that okay? A: No, that is not okay. Realize that our goal is not to mine the relationships among stars but to learn some database stuff. Your answer should contain exactly three movies and two actors. Q: I found the answer, just by looking at it. Is that okay? A: No. We need the SQL query.
|