11.2 KB · commit 40bb182
Department of Electrical & Computer Engineering
Course No: ECE 2215
Course Title: Data Base Systems
| Question No. | Question Description | Marks | CLO |
|---|---|---|---|
| Q.1 (a) | Discuss four significant differences between a file-processing system and a DBMS. | 04 | CLO1 |
| Q.1 (b) | What are the five main functions of a database administrator? | 03 | CLO1 |
| Q.1 (c) | How do we achieve referential integrity in DBMS? Provide necessary MySQL query with an appropriate example. | 05 | CLO2 |
| Question No. | Question Description | Marks | CLO |
|---|---|---|---|
| Q.2 (a) | Consider the following relation schema: customer (id, name, age, gender) order (id, product, price, date) Now, give expression in relational algebra to- (i) find name of the customers who are male. (ii) find name of all customers who have purchased car as product. (iii) find the details of all customers who have purchased "phone" as product and the price is less than $300. | 05 | CLO2 |
| Q.2 (b) | Differentiate among Superkey, Candidate Key and Primary Key with an appropriate example. | 03 | CLO1 |
| Q.2 (c) | For each expression, explain in words what the expression does. Where takes(id, course, sec_id, sem, year, grade) (i) σyear≥2009(takes)⋈student (ii) Πid,name,course_id(student⋈takes) | 04 | CLO2 |
| Question No. | Question Description | Marks | CLO |
|---|---|---|---|
| Q.3 (a) | Consider the following E-comerce database: client (c_no, name, city, state, baldue) product (p_no, description, profit_percent, quantity, sell_price, cost_price) salesman (s_no, name, city, state, sal_amount, target, sold_yearly, remarks) Now write the appropriate MySql code to execute the following query: (i) Change the city of client no "C0005" to "Barishal". (ii) Delete all salesmen whose salaries are equal to 35000 Tk. (iii) Add a column called "Telephone" of datatype numeric and size = '11' to the client table. (iv) Find products whose selling price is more than 500. Calculate a new selling price as original price15. Rename the new column in the output as new_price. (Note: "E-comerce" and "MySql" printed verbatim from original question paper)* | 08 | CLO2 |
| Q.3 (b) | Define entity and attribute. Explain the following attributes- (i) Multi-valued (ii) Derived (iii) Composite | 04 | CLO4 |
| Question No. | Question Description | Marks | CLO |
|---|---|---|---|
| Q.4 (a) | Consider the following E-comerce database: client (c_no, name, city, state, Baldue) product (p_no, description, profit_percent, quantity, sell_price, cost_price) salesman (s_no, name, city, state, sal_amount, target, sold_yearly, remarks) order (order_no, client_no, order_date, delivery_address, salesman_no, del_type, del_date, order_status) order_details (order_no, product_no, quantity_ordered, product_rate) (i) Find the total value of each product sold. (ii) Find the products and their quantities for the orders placed by client no "C0001" and "C0002". (iii) Find the product no and description of the products not being sold. (iv) Find if the product "Lyera Top" has been ordered by any client and print the client_no, name to whom it was sold. (Note: "E-comerce" and "Lyera Top" printed verbatim from original question paper) | 12 | CLO2 |
| Question No. | Question Description | Marks | CLO |
|---|---|---|---|
| Q.5 (a) | What is ER diagram? Illustrate different types of relationship that can be represented in ER diagram. | 04 | CLO1 |
| Q.5 (b) | Compute the closure of the following set F of functional dependencies for relational schema r (A, B, C, D, E). A→BC CD→E B→D E→A List the candidate Keys for R. | 04 | CLO1 |
| Q.5 (c) | Given a relation R (A, B, C, D) and functional dependency at FD = { AB → CD, B → C }. Determine whether the given R is in 2NF? If not, convert it into 2NF. (Note: "functional dependency at FD" printed verbatim from original question paper) | 04 | CLO1 |
| Question No. | Question Description | Marks | CLO | ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Q.6 (a) | Differentiate between normalization and canonical cover in DBMS. | 03 | CLO1 | ||||||||||||||||||||||||||||||||||||
| Q.6 (b) | Define Functional dependency. Consider the following functional dependency set: FD={ A→BC, CD→E, B→D, E→A } Find the canonical form of the FD set. | 05 | CLO1 | ||||||||||||||||||||||||||||||||||||
| Q.6 (c) | Consider the following table:
Is there any data redundancy in the above table? What kinds of problems/ anomalities it will produce for this table in future? (Note: "problems/ anomalities" printed verbatim from original question paper) | 04 | CLO1 |
| Question No. | Question Description | Marks | CLO | ||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Q.7 (a) | Explain the ACID properties of transaction. | 04 | CLO1 | ||||||||||||||||||
| Q.7 (b) | Define conflict serializability. Check whether the following schedule is a conflict serializable or not.
| 04 | CLO3 | ||||||||||||||||||
| Q.7 (c) | Consider the following schedule:
Using precedence graph find whether the schedule is serializable or not. If serializable, then find the order of execution. | 04 | CLO3 |
| Question No. | Question Description | Marks | CLO |
|---|---|---|---|
| Q.8 (a) | What is deadlock? Consider the following wait-for-graph:![]() Determine whether the schedule contains any deadlock or not. (Refer to the Wait-for-Graph Diagram and Detailed Text Representation below) | 05 | CLO1 |
| Q.8 (b) | What is SQL injection attack? Describe the precautions that should be taken to prevent this attack. | 05 | CLO4 |
| Q.8 (c) | Explain weak and strong entity set with appropriate example. | 02 | CLO1 |
Figure 2021_Q8.a — Wait-for-graph for deadlock detection (Source: Page 2, Q.8(a))
Vertices (Transactions): V={T1,T2,T3,T4,T5}
Directed Edges (Wait-for Dependencies): E={(T1,T4),(T1,T2),(T1,T3),(T4,T5),(T5,T2),(T2,T4)}
Cycle Analysis & Deadlock Detection: