0% found this document useful (0 votes)
8 views11 pages

BCA-C301: B. C. A. (Third Semester) EXAMINATION, 2023-24

Uploaded by

snegi2290
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views11 pages

BCA-C301: B. C. A. (Third Semester) EXAMINATION, 2023-24

Uploaded by

snegi2290
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

Roll No. …………………..

BCA–C301
B. C. A. (Third Semester)
EXAMINATION, 2023-24
DATABASE MANAGEMENT SYSTEM
1
Time : 22 Hours
Maximum Marks : 60
Note : All questions have to attempted.
Section—A
1. Multiple choice questions : 1 each
(a) What is DBMS ? (CO1, BL-1)
(i) DBMS is a collection of queries
(ii) DBMS is a high-level language
(iii) DBMS is a programming language
(iv) DBMS stores, modifies and retrieves data
(b) In which of the following formats data is stored in
the database management system ? (CO1, BL-1)
(i) Image
(ii) Text
(iii) Table
(iv) Graph

P. T. O.
[2] BCA–C301

(c) The values appearing in given attributes of any


tuple in the referencing relation must likewise
occur in specified attributes of at least one tuple
in the referenced relation, according to
.................. integrity constraint. (CO2, BL-1)
(i) Referential
(ii) Primary
(iii) Referencing
(iv) Specific
(d) The ability to query data, as well as insert, delete,
and alter tuples, is offered by ................... .
(CO2, BL-1)
(i) TCL (Transaction Control Language)
(ii) DCL (Data Control Language)
(iii) DDL (Data Definition Language)
(iv) DML (Data Manipulation Language)
(e) .................. is a set of one or more attributes taken
collectively to uniquely identify a record.
(CO2, BL-1)
(i) Primary key
(ii) Foreign key
(iii) Super key
(iv) Candidate key
[3] BCA–C301

(f) Which of the following set should be associated


with weak entity set for weak entity to be
meaningful ? (CO2, BL-1)

(i) Neighbour set

(ii) Strong entity set

(iii) Owner set

(iv) Identifying set

(g) ........................ operations do not preserve non-


matched tuples. (CO3, BL-1)

(i) Left outer join

(ii) Inner join

(iii) Natural join

(iv) Right outer join

(h) Which of the following key is required in to


handle the data when the encryption is applied to
the data so that the unauthorised user cannot
access the data ? (CO2, BL-1)

(i) Primary key

(ii) Authorised key

(iii) Encryption key

(iv) Decryption key

P. T. O.
[4] BCA–C301

(i) Dates must be specified in the format :


(CO2, BL-1)
(i) mm/dd/yy
(ii) yyyy/mm/dd
(iii) dd/mmlyy
(iv) yy/dd/mm
(j) SELECT ................. .
FROM instructor
WHERE dept name = ‘Comp. Sci.’;
Which of the following should be used to find the
mean of the salary ? (CO3, BL-1)
(i) Mean(salary)
(ii) Avg(salary)
(iii) Sum(salary)
(iv) Count(salary)
(k) SELECT name .................. instructor name,
course Id
FROM instructor, teaches
WHERE instructor.ID = teaches.ID;
Which keyword must be used here to rename the
field name ? (CO3, BL-1)
(i) From
(ii) Rename
(iii) As
(iv) Join
[5] BCA–C301

(l) For select operation the .................. appear in the


subscript and the ............... argument appears in
the paranthesis after the sigma. (CO2, BL-1)
(i) Relation, Operation
(ii) Relation, Predicates
(iii) Operation, Predicates
(iv) Predicates, Relation
2. Attempt any four of the following : 3 each
(a) What are the different types of Mapping
Constraints in three architecture ? (CO1, BL-1)
(b) Define loss less join decompositions.
(CO5, BL-2)
(c) Explain different of aggregate function in Sql
with proper example. (CO3, BL-2)
(d) You have a table named students with the
following columns, write down the query for
following question. (CO3, BL-6)
student_id (unique identifier for each student)
name (name of the student)
grade (the grade of the student, which can be ‘A’,
‘B’, ‘C’, or ‘D’)
(i) Write an SQL query to count the number of
students in each grade.
(ii) Add new column student id and student
name.
(iii) Write query to insert 5 values in Student
Table.
(e) Explain different types anomaly in DBMS.
(CO1, BL-2)

P. T. O.
[6] BCA–C301

Section—B
3. Attempt any two questions : 6 each
(a) What is algebraic operations in DBMS. Consider
a relational database with two tables : Students
and Courses. The Students table has attributes :
StudentID, FirstName, LastName, and GPA. The
Courses table has attributes : CourseID,
CourseName, and Instructor. (CO3, BL-6)
(i) Write a relational algebra expression to find
the names of students (i.e., FirstName and
LastNanie) who have a CPA greater than
3.5.
(ii) Write a relational algebra expression to
retrieve a list of courses (i.e., CourseName)
taught by an instructor named ‘Smith’.
(b) Case Study : In a university, a Student enrolls in
Courses. A student must be assigned to at least
one or more Courses. Each course is taught by a
single Professor. To maintain instruction quality,
a Professor can deliver only one course.
Create an ER Diagram of the following case
defining all the step. (CO2, BL-6)
(c) What are the different types of keys in SQL ?
Explain all keys with proper example.
(CO2, BL-2)
[7] BCA–C301

4. Attempt any two questions : 6 each


(a) Create two tables : uscs_employee and
uscs_department. (CO2, BL-6)
The employee table has employee’s Id,
employee’s name and employee’s department
number.
The department table has department number,
department name and department location. Solve
the following queries :
(i) Display the structure of the uscs_employee
table.
(ii) Display the structures of uscs_department
table.
(iii) Insert at least three department details in the
uses_department table.
(iv) Insert employee details working in the
corresponding departments as in the
uscs_department table.
(v) Display the data uscs_department and
uscs_employee table.
(vi) Examine the error message by inserting a
value in employee_department_no which is
not there in uscs_department table
deprtment_no, write error message and
reason.

P. T. O.
[8] BCA–C301

(b) Discuss the concept of functional dependencies in


the context of database normalization. Explain
what functional dependencies are and how they
are related to the process of normalizing a
relational database. Provide examples to illustrate
different types of functional dependencies.
(CO4, BL-2)
(c) Discuss the two main approaches to deadlock
handling in a DBMS : deadlock prevention and
deadlock detection and resolution. Compare and
contrast these approaches, highlighting their
advantages and disadvantages. (CO5, BL-6)
5. Attempt any two questions : 6 each
(a) Explain the concept of ACID properties in the
context of database management systems
(DBMS). Define each of the four ACID
properties (Atomicity, Consistency, isolation, and
Durability) and discuss their significance in
ensuring data integrity and reliability in a
database. (CO5, BL-6)
(b) Explain three tier architecture in DBMS.
(CO1, BL-2)
(c) You’ve been tasked with designing and managing
a database for an online bookstore. The database
will store information about books, authors,
customers, orders, and shipments. You need to
create a database schema and develop SQL
commands to perform various tasks for the online
bookstore. (CO3, BL-6)
[9] BCA–C301

Requirements and Entities :


• Books : Each book has a unique BookID, a
title, an ISBN, a publication year, a price, and
an inventory quantity. Books can belong to
specific categories (e.g., Fiction, Non-
Fiction).
• Authors : Authors are identified by a unique
AuthorID and have a first name, last name,
and a bio.
• Customers : Customers have a unique
CustomerlD, a first name, a last name, an
email address, and a shipping address.
• Orders : Orders have a unique OrderID, a
creation date, and are associated with a
specific customer.
• Order Details : Each order may contain
multiple books. For each book within an
order, you need to track the quantity ordered,
the book’s price at the time of the order, and
any discounts applied.
• Shipments : Shipments have a unique
ShipmentID, a tracking number, and a status
(e.g., Shipped, Delivered). Each shipment
corresponds to a specific order.

P. T. O.
[ 10 ] BCA–C301

Tasks :
SQL Commands for Database Setup :
Write an SQL command to create the tables for
the database, incorporating the schema you
designed.
Specie’ the data types and constraints for each
column as needed.
Data Population :
Insert sample data for two books, three authors,
two customers, one order, and one shipment.
Book Inventory Update :
Write an SQL command to update the inventory
quantity of a specific book, decreasing it by 5.
Customer Order :
Create a new order for a customer, including
order details for two books.
Calculate the total cost of the order.
Order Tracking :
Write an SQL query to retrieve the order details
for a specific customer’s order, including the
book titles, quantities, and total cost.
Author Search :
Create an SQL query to find authors whose last
name contains ‘Smith’ and list their book titles.
[ 11 ] BCA–C301

Shipment Status Update :


Update the status of a specific shipment to
‘Delivered’ using an SQL command.
Data Deletion :
Write SQL commands to delete a book, an author,
and a customer, ensuring that any related records
(e.g., orders) are handled appropriately.
Please provide SQL commands for each task,
along with explanations where necessary. Use
your designed database schema and populate the
database with the provided sample data.

BCA–C301

P. T. O.

You might also like