
INTRODUCTION TO
DATABASE (IT244)
ASSIGNMENT 1
(LAST DATE TO
SUBMIT: 20/02/2016)
Q1: Consider the below schema for a library database and write relational algebra expressions for the
following queries [1.5 Marks]
1. Give all authors’ names born after 1940. [0.25 Point]
π authornames(σ birthyears >1940(Product))
2. Give the names of libraries in Sydney. [0.25 Point]
π libname(σ city= Sydney (Branch))
3. Give the cities where each book is held. [0.25 Point]
π city,book.isbn(σ Branch.libname = Instock.libname and Instock.isbn = Book.isbn
(Branch*Instock*Book))
2
1. Author ( authorname, citizenship, birthyear)
2. Book (isbn, title, authorname)
3. Topic (isbn, subject)
4. Branch (libname, city)