Q1. Define the term foreign key. What is this concept mainly used for?
Q2. Describe the entity integrity and referential integrity constraints. Why each is considered significant?
Q3. describe why are duplicate tuples not permitted in a relation?
Q4. Consider the given relations:
WORKS(Pname, Cname, Salary)
LIVES(Pname, Street, City)
Where Pname = Person name, Cname = Company name and Mgrname = Manager name.
prepare down the SQL queries for the given:
a) List all the names of people who work for the company Wipro all along with the cities they live in.
b) Find out the names of the persons who live and work in the similar city.
c) Find out the names of the persons who don’t work for ‘Infosys’.
d) Find out the persons whose salaries are more than that of the entire Oracle employees.
e) Find out the names of the companies which are located in every city where the company ‘Infosys’ is situated.
Q5. Describe the Inner Join concept in the Relational Algebra.