dbms questions cse ivsem

4

Click here to load reader

Upload: rohit-tiwari

Post on 12-Jul-2016

9 views

Category:

Documents


3 download

DESCRIPTION

dbms

TRANSCRIPT

Page 1: Dbms Questions Cse Ivsem

Database Management Systems (DBMS) 

Q1. What are the advantages of using the DBMS approach over File Processing System? 

Q2. A database is being constructed to keep track of the teams and games of sports league. A team has no. of players, not all of whom participate in each game. It is desired to keep track of players participating in each game for each team, and the result of that game. Design an ER schema diagram for this application, stating any assumption you make. 

Q3. Reduce the above ER diagram into tables. 

Q4. Discuss the entity integrity and referential integrity constraints. Why is each considered important? 

Q5. What do you mean by Outer Join? Also explain: 

a) Left Outer Join b) Right Outer Join c) Full Outer Join 

Q6. What are the different Data Models? Also explain its various types with diagrams and examples. 

Q7. What are the different Database Users and their specific functionalities? 

Q8. What is the role of Data Administrator? 

Q9. Explain the various levels of Data Abstraction. Differentiate between Physical Data Independence & Logical Data Independence. 

Q 10. Consider a customer table with the following fields:‐cust_id, cust_name, cust_branch, cust_account_no. Write the following commands in SQL. 

(a) Create the above table and insert four rows. 

(b) Add a new column cust_salary& add values in all 4 rows. 

(c) Change the name of a customer from John to Jack. 

(d) Sort the data and eliminate duplicate rows. 

(e) Create a primary key on the table. 

(f) List all the tables in database. 

(g) View all the column definitions of this table. 

(h) Count the no of rows. 

(i) List the cust_account_no of all the customer whose name starts with ‘A’ & has branch Gurgaon. 

Page 2: Dbms Questions Cse Ivsem

(j) Delete the rows where address has not been supplied. 

 

Q11. Consider the following schema 

Boats(bid, bname, color) 

Sailors(sid, sname, rating, age) 

Reserves(sid, bid, day).  

Write the following queries using Relational Algebra. 

a) Find the names of sailors who have reserved boat 103 

b) Find the name of sailors who reserved a red boat 

c) Find the color of boats reserved by Dustin 

d) Find names of sailors who have reserved a red or a green boat 

e) Find names of sailors who have reserved a red and a green boat 

f) Find the names of sailors who reserved at least two boats 

g) Find the sids of sailors with age over 20 who have not reserved a red boat 

h) Find the sids of sailors who reserved all boats 

 

Q 12. Define the following terms with reference to tuple relational calculus. 

a) Tuple Variable b) Range relation c) Atom d) Formula e) Relation 

Q 13.Describe in detail sequential, direct and index file organization techniques with relative merits and demerits. 

Q 14. Why do we need to provide foreign key constraints? How can you enforce referential integrity? 

Q 15. What is the difference between Relational Algebra and Relational Calculus? Explain the different operators of relational algebra. 

Page 3: Dbms Questions Cse Ivsem

Q 16. Discuss the Client/Server architecture with the help of a diagram. Also explain three tier architecture. 

Q 17. What do you mean by Functional Dependencies and Normalization? Explain various kinds of Normalization? 

Q 18. Explain: 

a) Parallel Database b) Data Mining and Data Warehousing c) Hashing and B‐ Tree index files d) Direct Files and sequential files 

Q 20. Compare the deferred and immediate modification versions of log based recovery scheme. Also discuss in terms of ease of implementation and overhead cost. 

Q 21.Explain concurrency control and recovery system. 

Q 22. What is serializability? What are the different types of serializability? 

Q 23.Explain the Boyce‐Codd normal form with an example. Also state how itdiffers from that of 3NF 

Q 24.Define a transaction. Then discuss the following with relevant examples : 

1)  A read only transaction 2)  A read write transaction 3)  An aborted transaction 

 With a neat sketch discuss the states a transaction can be in. 

Q 25. Consider the following two transaction: 

  T 12: read(A); 

  read (B); 

  if A = 0 then B := B+1; 

  write (B) 

  T13: read (B); 

  read (A); 

  if B = 0, then A:= A+1; 

  write (A); 

Page 4: Dbms Questions Cse Ivsem

Add lock and unlock instructions to transactions T12 and T13 , so that they observe the two‐phase locking protocol. Can the execution of these transactions result in a deadlock? 

Q 26. Explain the various mapping constraints on relationships. Also give examples. 

Q 27.What are ACID properties? Explain in detail. 

Q 28. Two transactions are not interleaved in a history if every operation of one transaction precedes every operation of the other. Give an example of a serializable history H that has all of the following properties: 

i) Transactions T1 and T2 are not interleaved in H. 

ii)     T1 precedes T2 in H. 

iii)     In any serial history equivalent to H2, T2 exceeds T1. The history may include more than two transactions. 

Q 29. Explain the significance of checkpoints in log based recovery. 

Q 30.Explain the different types of keys in Relational Model.