Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Final Dbms

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

Write short notes on any four of the following : 4x5=20

Differentiate between primary and (b) Clustering Indices


secondary indexes in the context of file
organization Write short notes on the following : 3x5=15
(i) Web Databases

Write short notes on the following : 4x5=20


Differentiate between data . security and data
integrity. (a) Locks
(c) Database Errors

Differentiate between the concepts of


Logical data independence and . Physical
data independence in DBMS. Write short notes on the following : 4x5=20
(a) Any 4 Commands of DML

Write short notes on the following : 45=20 (d) 3-Tier Architecture


(b) Hashed File Organization
(c) DML Commands used in DBMS (any four)
(d) Functional Dependency Explain any five of the following : 5×4=20

(d) Cartesian product and division operations


in relational algebra
Write short notes on following : 20
(i) Precedence graph for serializability check (e) Inverted file organisation
(ii) Types of Indexes in DBMS (f) Client-server databases

Write short notes on the following : 4x5=20 Explain the following with the help of an
(b) Clustering Indexes and their example : 8
Implementation (i) Integrity constraints and its types
(c) Shadow Paging
(d) Weak Entity along with an example.
(e) Specialisation in ERD with an appropriate
example. Discuss the following relational constraints : 10
(i) Domain
Write short notes on any four of the following : (ii) Entity
(c) Indexed Sequential File Organisation (iii) Referential Integrity
(iv) Key Constraint
With the help of an appropriate example for
each, explain the following basic set
operations : 10
(i) UNION Consider the relation SUPPLIER given
(ii) INTERJECTION below, where S# and P# are keys, the
(iii) SET DIFFERENCE functional dependency set FD is
(iv) CARTESIAN PRODUCT FD = {S# P# -4 city, S# ---> city)
SUPPLIER
What is the role of Indexing in file S# X X X Y Y
organization ? Explain the following in P# 1 2 3 1 2
relation to file organization, with the help CITY DELHI DELHI DELHI GOA GOA
of an example for each : 10 Now, perform the following :
(i) Primary Index (i) Determine the highest normal form of
(ii) Secondary Index the relation SUPPLIER. 2
(iii) Multilevel Indexing (ii) Normalize the relation SUPPLIER to
the next higher normal form.
Explain the following in brief : 8 (iii) Discuss the Deletion and Insertion
(i) Client-Server Databases anomalies, which can occur in the
relation SUPPLIER.

Consider the Relational Database Schema With the help of a suitable example,
given below : discuss the insertion, deletion and updation
Employee (empcode, empname, empaddress, anomalies that can occur in a database.
salary) Briefly discuss the mechanism to remove
Department (deptcode, deptname, such anomalies.
deptlocation)
Perform the following queries using SQL
and Relational Algebra : 5
(i) Find details of the departments Explain the different forms of
located in Delhi. Authorization techniques.
(ii) Find the names of employees whose
salary is more than 4 lakhs per annum.
What are integrity constraints ? Explain
What do you understand by the term the various types of integrity constraints
functional dependency ? Explain the with suitable examples.
following functional dependencies : 10
(i) Full functional dependency What are integrity constraints ? Discuss
(ii) Partial functional dependency the various types of integrity constraints
(iii) Transitive functional dependency that can be imposed on databases.
(iv) Trivial functional dependency
How are database security and database
integrity related ? Briefly discuss the
What is Functional Dependency ? Explain different levels of security measures which
single-valued dependency with an example. may be considered to protect the database.

What are integrity constraints ? Discuss What are integrity constraints ? Explain 5
the entity integrity and referential two types of integrity constraint with the
integrity constraints with suitable help of an example.
example.
What is data integrity ? Does data
integrity have any relationship with data
Describe the relationship between data security ? Justify- your answer with the
security and data integrity, with the help help of example and diagram.
of a diagram.
Discuss any two levels of security mechanisms
to protect database.
Describe the relationship between Data
Security and Data Integrity, with the help
of a diagram. Give the difference between operating
system and database security.
What are integrity constraints ? What for
they are required in databases ? Briefly
discuss the different types of integrity How do you implement a hierarchical data
constraints. model ? Explain through an illustration.

Explain the data models, used to structure


the data in the database systems.
Explain the two integrity rules with the help of an
example for each.
Compare and contrast serial file 300.
organization technique with indexed A disk pack consist of 15 double side disks.
sequential technique in terms of storage, (i) Calculate record size R in bytes.
access and other features. (ii) Calculate the blocking factor (bfr) and
the number of file blocks b, assuming
an unspanned organization.
What is a hashed file organization ? What are its (iii) Calculate the average time it takes to
advantages and disadvantages ?
find a record doing a linear search on
the file , in which file blocks are not
Explain the Sequential file organization.
stored contiguously.
Give the advantages and disadvantages of it.
(iv) Assume that the file is ordered by
"Branch-Code", calculate the time it
What is the difference between DBMS and
takes to search for a record given its
RDBMS ? Under what situations is it
better to use File-based System than "Branch_Code", by using a binary
Database System ? search.

With the help of a suitable example, explain


inverted file organisation.
With the help of a suitable example, explain
inverted file organisation.
Discuss the importance of file organisation
in databases. Mention the different types of What is a B + tree ? Why is a 13 + tree better
file organisations available. Discuss any structure than a B-Tree for implementation of an
one of the mentioned file organisations in index sequential file ?
detail.
What are the two advantages of a B-Tree
as an index ? Write the important features
of B-Tree of order N.
A file has r = 10,000 Bank Account records
of fixed length. Each record has the What are Indexes in DBMS ? What is the
following fields : utility of Indexes in DBMS ? Under what
Name (20 bytes), Account_No(8 bytes), situations B-tree Indexes are preferrable
address (40 bytes), Balance (15 bytes) and over Binary Search Tree Indexes ?
Branch-Code (5 bytes).
The file is stored on a disk with the following Can we use Binary Search Tree (BST) as
characteristics : Indexes ? Justify. If we use BST as Index,
Block Size = 512 bytes, Inter Block then what can be the possible problems ?
Gap = 128 bytes, number of block per What will be the solution for those
track = 15, Number of tracks per sector = problems ?
What is the need of Indexing in DBMS ? 7
How do we implement "B-Trees" as an Index •? Explain the significance of primary Index
Give an example to illustrate. What are its with the help of an example.
advantages ?
What do you understand by Query
Can we use Binary Search Tree (BST) for Optimization in DBMS ? How does
indexing ? Justify. relational algebra help in Optimizing the
Query ? Discuss with suitable example.
How do B-tree indexes differ from Binary List the operators used in relational
search tree indexes ? algebra and briefly explain them.

Discuss the use of B-Tree as a structure for


creating index, with the help of an example What is Query Optimization ? Discuss the
in support. role of Relational Algebra in query
optimization.

Write in detail about B-Tree structure for


indexes with a neat diagram.
What do you understand by the term Query
Define primary and clustering indexes. Optimization ? Discuss the role of
Briefly discuss implementation of relational algebra in Query Optimization.
clustering indexes. List the operators used in relational
algebra and discuss the operation of each,
What is the need of indexes in DBMS ? with suitable example.
Compare primary; secondary and clustering
indexes. Which of these indexes are dense ? What are nested queries ? explain with the
Give steps to perform implementation of help of an example.
clustering indexes.
Consider the following schema :
Compare primary, secondary and clustering Employee (ENo, EName, City, Basic_Sal,
indexes. Which of these indexes are dense Job_Status)
and which are not ? How is implementation Projects (PNo, PName, PCategory)
of clustering indexes performed ? Works_In (PNo, ENo, PDuration)
Write the appropriate SQL queries for the
Discuss briefly about Sparse and Dense following :
Indexes with the help of an example. (i) Display all the names of
the employees who are working in
‘‘PAY_ROLL FOR ABC COMPANY’’
project.
(ii) Display the ENo, EName of all the Consider the following relations in a
employees who are working in database that maintains the official tours
PNo = 123. of sales executives in a marketing
(iii) Find the average salary of all company.
the employees working in a project Sales_Executive (SEID, Dept_No, Joining_year)
with PName ‘‘ADMINISTRATION Official_Tour (Tour_ID, from_city, to_city,
dep_date, ret_date, SEID)
MODULE OF XYZ’’ Company.
Expenditure (Tour_ID, Amt_spent)
Write the queries using SQL :
(i) Find the details of Official_Tour
relation whose expenses exceed
RS 5000.
(ii) Find the total official tour expenses
incurred by sales executives from
Dept_No = DN1.
(iii) Find the SEID’s of sales executives
who took trips to Bangalore for seven
days with expenses ranging between
Rs 5000 and Rs 9000.
Consider the following three tables : 10
student (student_id, name, date_of_birth)
registers ((student_id, course_id) Consider ‘‘Library Management System’’
course (course_id, course_title, credits) which keeps the following tables :
Write the SQL commands for the following Book (isbn_no, title, author, publisher,
edition, year)
queries :
Book_Access (access_no, isbn_no,
(i) List all the courses in alphabetical date_of_purchase)
order of course title. Member (m_name, m_id, m_address,
(ii) Make a list of students who have m_phone)
registered for course whose course_id Issue_Return (access_no, m_id,
is “MCS-23”. expected_return_date, actual_return_date)
(iii) Count the total number of students in Specify the following queries in SQL :
(i) Find m_id and m_name of the
each course.
members who have got at least one
(iv) List all the courses whose credits are book issued to themselves.
less than 4. (ii) List the book details for the books
(v) List all the students who have which were purchased after January
registered for more than one course. 2017.
(iii) List all the books on title
‘‘Databases’’. This list should be
sorted on author’s name.
(iv) Find the members who have not got Consider the following tables :
any book issued. WORKS(Pname, Cname, Salary)
LIVES(Pname, Street, City)
Consider the following relational database LOCATED(Cname, City)
schema : MANAGER(Pname, Mname)
Employer (ecode, ename, eaddress, esalary) Write a query in SQL for the following : 10
Project (pcode, pname, pduration) (i) List the names of the people who work
Works for (ecode, pcode, duration) for the company Wipro' along with
Perform the following queries using SQL the cities they live in.
and relational algebra : (ii) Find the people who work for the
(i) Find the name of the employees company `Infosys' having salary
whose salary is less than 5 lacs per greater than 50,000.
annum. (iii) List the names of the people, along
(ii) Find the details of the employees with the street and city addresses.
working on the project "Clusters". (iv) Find the persons whose salaries are
more than that of all of the 'Oracle'
employees.
(v) Find the names of the persons who do
not work in `Infosys'.
Consider the following relations for a
database that keeps a track of business Consider the following relations 8
trips of salespersons in a sales office : STUDENT (Name, Roll_Number,
SALEPERSON (SSN, Name, Start Year, Teacher_ID, Programme, Semester, Subject)
Dept_No) DEPARTMENT (Dep_ID, Programme,
TRIP (SSN, From_City, To_City, Teacher_ID)
Departure_Date, Return_Date, TEACHER(Teacher_ID,Dep_ID,
Trip_ID) Name, Subject)
EXPENSE (Trip_ID, Account#, Amount) Write the following queries using SQL :
Specify the queries in SQL. (i) List name of all the teachers who
(i) Find the details (all attributes of belong to Dep_ID ='4' and take
TRIP relation) for trips whose "Graph Theory", subject.
expenses exceeds $ 2000. (ii) List names of all the students who
(ii) Find the SSN of salesmen who took study in Semester-II of BCA
trips to 'Honolulu'. programme and are taught by
(iii) Find the total trip expenses Teacher_ID = '1'.
incurred by the salesman with (iii) Find the name of all the teachers who
SSN = '234-56-7890'. teaches to the student whose
ROLL Number ='101'.
(iv) Find the name of all the students who school_of studies)
are in Is' semester of MCA programme Taught (Student_ID, Course_ID, Year,
and are taught by Prof. Ajay. Instructor ID)
Write SQL statements for the following :
To retrieve the names of all 3rd year
students of MCA Program who have done
courses under Instructor ID-001
(ii) To retrieve the names of all courses taught
by instructor-002 between 1996-2001 and
total number of students attended the
courses.

Write SQL commands for each of the


Write SQL statements to perform the following. Also illustrate the usage of each
following queries on the relations given command through suitable example.
below : (i) Creation of views
BOOK (Book_ID, Title, Publisher_ID, (ii) Creation of sequences
Year_of Pub, Price) (iii) Outer join
AUTHOR (Author_ID, Book_ID, (iv) To give access permission to any user
Author Name)
PUBLISHER (Publisher_ID, Book_ID, Consider the following Relations :
Address, Name_of Pub, No._of Copies) Employee (EName, EId, Addr I, Addr2,
(i) Find the name of authors whose books City, State)
are published by "ABC Press". Works (EId, Branch, Dept_Name,
(ii) Find the name of the author and price Dept_No, Dept_Head)
of the book, whose Book_ID is '100'. Write the SQL statements for the
(iii) Find the title of the books which are following : 5
published by Publisher_ID '20' and (i) Find all the ENames of employees
are published in year 2011. who work in FINANCE department of
(iv) Find the address of the publisher who Delhi Branch.
has published Book_ID "500". (ii) Find the Dept_Head for the employee
if EName and EId are given.
Consider the following relational schema:
Student (Student_ID, student_name, program)
Course (Course_ID, Course_name,
What is SQL ? Explain its important (ii) Project
features. (iii) Join

Define Data Manipulation Language What is data independence ? Explain two 7


(DML) of SQL. List and explain various types of data independence with the help
DML commands. of an example for each.

What is DDL ? How it is different from 6


Explain the working of GROUP BY clause. DML ? Briefly explain guidelines for creation
What is the difference between the of table.
WHERE and HAVING clause in SQL ?
What do you mean by ALTER TABLE
command ? Write its syntax in any four possible
situations where it is used.

Define a JOIN operation, How is this


Where are Having and Group by clauses different from Cartesian product in
used ? relational algebra ? Explain with the help
What will be the output of the following of an example.
SQL statement on the Person relation
defined above in Q. no. 2(c) ?
Select Name, Max (Salary)
From Person
Group by Name Having Max (Salary) > 15000
What is a join in DBMS ? Explain three 7
Explain the meanings of the following clauses types of join with the help of an example
with appropriate example for each : [4] for each.
(i) Group by clause
(ii) Having clause

What is Relational Algebra ? What is the


utility of relational algebra ? Is SQL
related to relational algebra ? Comment on
it. Explain the following operations in the
relational algebra with the help of an
example for each :
(i) Select Explain the effect of a rollback operation
with an example.
available in a DBMS. Which data structure
Identify the following symbols in relational is suitable for creating indices and why ?
algebra. What operations do they perform ?
(i) 
(ii) 

Consider the 'F' and `G' sets of functional


dependencies, where
What are the reasons for fragmenting a F = —> C, —> D, E --> AD, E 111 and
relation ? What are the rules to be applied for G.{A—>CD,E—>AH}.
fragmenting a relation ? Check whether they are equivalent or not.
What is a data dictionary ? What should be
included in data dictionary ?

What is a weak-entity ? What are the restrictions


on weak entity ? Explain through an example.

What types of constraints violation take place


during insert operation ? Explain with an example

What is a precedence graph ? Why it is used ?


Write all the steps for constructing a precedence
graph.

Explain the concept of a simple authorization with


the help of an example.

Give suitable examples in support of your


discussion.

What is the need of indices in a database


system ? Mention the categories of indices

You might also like