Assignment 1: Submission Date: Tuesday, 7 September, 2010 (Start of Class)
Assignment 1: Submission Date: Tuesday, 7 September, 2010 (Start of Class)
Schema
Books (ID,Name,ISBN,Price,Author,Publisher,DatePublished)
Author(ID,FirstName,LastName,Country)
Exercise
1. Display book Name, ISBN and Price of all books with price between 100-500.
2. Display Author name and Average of its book prices. (Only use Books table)
3. Display Country and number of authors in that country.
4. Display Author Name and count of books of author with number of books > 3. (Only use
Books Table).
5. Display Publisher Name, count of books published and experience of publisher by that
publisher. If Books Published < 2 print ‘New’ in front of it. If Books Published > 2 print
‘Old’ in front of it. (Use only Books Table). Output Should have Publisher,Count of Books,
Experience. (Case query as discussed in lab).
6. Display Author Name, Book Name, Price of each Author with highest price only. (Only
use Books Table)
Submission Instructions
1. Use the same data as done in lab. You can get the data excel file from Lab 3 folder in DB
SEC A Lab.
2. You have to submit a printed copy of all the queries and its data output. Right click on
the Result screen on SQL Server, click select all, and then again right click and click copy
with headers.