Q.1.
Given the following relational schema
DIVISION(Div #, Div_Name, Director)
DEPARTMENT(Dept #, Dept_Name, Location, Div #)
EMPLOYEE(Emp #, Emp_Name, Salary, Address, Dept #)
State the following queries in SQL
a) Get the employee name, department name and division name for all employees whose salary is above Rs.20,000.
b) List the names of all employees who work in “Information Technology” Division.
c) List the departments and employees in each department located in “Mumbai”.
Q.2. Construct an E-R diagram for a hospital with a set of patients and a set of medical doctors. Associate with each patient a log of the various tests and examinations conducted.
Q.3. Discuss the various levels of data abstraction and explain task of DBA.
Q.4. with the help of block diagram explain basic structure of DBMS.
Q.5. write short notes on generalization specialization and weak entity set.
Q.6.
A university registrar’s office maintains data about the following entities: (a)
courses, including number, title, credits, syllabus, and prerequisites; (b) course
offerings, including course number, year, semester, section number, instructor(s),
timings, and classroom; (c) students, including student-id, name, and program;
and (d) instructors, including identification number, name, department, and title.
Further, the enrollment of students in courses and grades awarded to students
in each course they are enrolled for must be appropriately modeled.
Construct an E-R diagram for the registrar’s office. Document all assumptions
that you make about the mapping constraints.
Q.7. Explain view in detail with its benefit and limitation?
Q.8. Explain serializability in detail with appropriate example?
Q.9. Explain any five relational algebra operator?
Q.10. Consider the employee database of
employee (employee-name, street, city)
works (employee-name, company-name, salary)
company (company-name, city)
manages (employee-name, manager-name)
where the primary keys are underlined.
Give an expression in SQL for each of the following queries.
a. Find the names of all employees who work for First Bank Corporation.
b. Find the names and cities of residence of all employees who work for First
Bank Corporation.
c. Find the names, street addresses, and cities of residence of all employees
who work for First Bank Corporation and earn more than $10,000.
d. Find all employees in the database who live in the same cities as the companies
for which they work.
e. Find all employees in the database who live in the same cities and on the
same streets as do their managers.
f. Find all employees in the database who do not work for First Bank Corporation.
g. Find all employees in the database who earn more than each employee of
Small Bank Corporation.
h. Assume that the companies may be located in several cities. Find all companies
located in every city in which Small Bank Corporation is located.
i. Find all employees who earn more than the average salary of all employees
of their company.
j. Find the company that has the most employees.
k. Find the company that has the smallest payroll.
l. Find those companies whose employees earn a higher salary, on average,
than the average salary at First Bank Corporation.
Given the following relational schema
DIVISION(Div #, Div_Name, Director)
DEPARTMENT(Dept #, Dept_Name, Location, Div #)
EMPLOYEE(Emp #, Emp_Name, Salary, Address, Dept #)
State the following queries in SQL
a) Get the employee name, department name and division name for all employees whose salary is above Rs.20,000.
b) List the names of all employees who work in “Information Technology” Division.
c) List the departments and employees in each department located in “Mumbai”.
Q.2. Construct an E-R diagram for a hospital with a set of patients and a set of medical doctors. Associate with each patient a log of the various tests and examinations conducted.
Q.3. Discuss the various levels of data abstraction and explain task of DBA.
Q.4. with the help of block diagram explain basic structure of DBMS.
Q.5. write short notes on generalization specialization and weak entity set.
Q.6.
A university registrar’s office maintains data about the following entities: (a)
courses, including number, title, credits, syllabus, and prerequisites; (b) course
offerings, including course number, year, semester, section number, instructor(s),
timings, and classroom; (c) students, including student-id, name, and program;
and (d) instructors, including identification number, name, department, and title.
Further, the enrollment of students in courses and grades awarded to students
in each course they are enrolled for must be appropriately modeled.
Construct an E-R diagram for the registrar’s office. Document all assumptions
that you make about the mapping constraints.
Q.7. Explain view in detail with its benefit and limitation?
Q.8. Explain serializability in detail with appropriate example?
Q.9. Explain any five relational algebra operator?
Q.10. Consider the employee database of
employee (employee-name, street, city)
works (employee-name, company-name, salary)
company (company-name, city)
manages (employee-name, manager-name)
where the primary keys are underlined.
Give an expression in SQL for each of the following queries.
a. Find the names of all employees who work for First Bank Corporation.
b. Find the names and cities of residence of all employees who work for First
Bank Corporation.
c. Find the names, street addresses, and cities of residence of all employees
who work for First Bank Corporation and earn more than $10,000.
d. Find all employees in the database who live in the same cities as the companies
for which they work.
e. Find all employees in the database who live in the same cities and on the
same streets as do their managers.
f. Find all employees in the database who do not work for First Bank Corporation.
g. Find all employees in the database who earn more than each employee of
Small Bank Corporation.
h. Assume that the companies may be located in several cities. Find all companies
located in every city in which Small Bank Corporation is located.
i. Find all employees who earn more than the average salary of all employees
of their company.
j. Find the company that has the most employees.
k. Find the company that has the smallest payroll.
l. Find those companies whose employees earn a higher salary, on average,
than the average salary at First Bank Corporation.
No comments:
Post a Comment