The database depicted in the Visio diagram describes Proceeding, Article, Researcher, article PublishedIn a proceeding, article WrittenBy researchers and proceedings EditedBy researchers.
- Proceeding(ISBN, bookname, year, publisher): lists all the proceedings in existence, with the proceeding title, the year of publication and the publisher
- Article(aID, title, subject): lists all the articles
- Researcher(rID, name, institution): lists all the people, including editors and authors, and their institution
- PublishedIn(aID, ISBN): For each proceeding, lists the article contained
- WrittenBy(rID, aID): For each person, lists all the article he/she has authored, one article can be co-authored by more than one
- EditedBy(rID, ISBN): For each proceeding, lists all its editors, there can be more than one
There are no duplicate rows in any of the tables.
Please read the script 10.sql carefully. It both defines and creates the sample database and has placeholders for putting in your answers.
You are supposed to produce the following queries. Most of them produce answers without modifying the database. For each such query, unless stated otherwise;
- Sort the results in ascending order
- Remove duplicates from the answer
So to assuming your answer without the above requirement, on a hypothetical database would have been:
SELECT a, b
You should actually have:
SELECT DISTINCT a, b
ORDER BY a ASC, b ASC;
You may, of course, use intermediate tables while producing your answers. You may need to explicitly DROP them once the answer is produced, so that you can run your queries again without getting errors.