) Define: Super Key, Candidate Key, Primary Key, Foreign Key, Alternate Key. B)

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

ACADEMY OF TECHNOLOGY 1ST Home Assignment Subject Name: Database Management Systems Discipline: IT Subject Code: IT-601 Semester:

6th

1. What are four main functions of a database administrator? Write the comparison between relational model,
network model & hierarchical model. 5+5 2. a) Design an E-R diagram for keeping to track the information for all teams in a league. You should store the matches played, the scores in each match, the players in each match and individual player statistics for each match for every team. b) Explain the difference between a weak and a strong entity set. 6+4 3. a) Define: Super key, Candidate key, Primary key, Foreign key, Alternate key. b) Define the concept of aggregation. Give a suitable example of where this concept is useful. 5+5 4. Write short notes on the following (any two): a) Specialization & Generlization b) Data Independence 2X5=10 c) DBMS architecture

5. a) Consider the following relational database , where the primary keys are underlined. 1X5=5 employee (person-name, street, city) works (person-name, company-name, salary) company (company-name, city) manages (person-name, manager-name) Give an expression in the relational algebra to express each of the following queries: a. Find the names and cities of residence of all employees who work for Bank of India. b. Find the names of all employees in this database who live in the same city as the company for which they work. c. Find the names of all employees in this database who do not work for Bank of India. d. Assume the companies may be located in several cities. Find all companies located in every city in which Bank of India is located. e. Give all employees of Bank of India a 10 percent salary raise. b) Consider the relation emp(empid, name,city, jobtype,salary_per_amum,deptno). Solve the follwing queries using SQL. 1X5=5 a.Create an empty table emp1 with same structure as emp. b. Fetch the records from Emp table whose city in between DELHI,BANGALORE,PUNE. c. Assume emp2 is another with same structure as emp. Retrive all records of emp1 those should not present in emp2? d. Assume Rs.1000 is given to the employees as commission. Calculate the sum of monthly salary and the commissions of each employee. e. Retrieve the records from Emp table whose jobs are same.

You might also like