JNTU

JNTU MCA 2022 DATABASE MANAGEMENT SYSTEMS Previous Question Paper (March/April - 2022 - R17)

MCA | 2022 | III | R17 | March/April - 2022

Answer PaperPaper Code: 843AAMaximum Marks: 75Time: 3 Hours

Answer any five questions

All questions carry equal marks

Main

1

Define ER diagram. What are additional features of ER diagrams? Explain in detail with suitable examples.

15 marks

Answer

An Entity-Relationship (ER) diagram is a graphical representation of entities and their relationships in a database, serving as a high-level conceptual data model. It depicts the logical structure of a database by identifying the objects (entities) of interest, their attributes, and the associations (relationships) between them.

Beyond basic entities, attributes, and relationships, advanced ER modeling includes several features that enhance the representation of complex data requirements:

  • Generalization and Specialization: This is a top-down approach where a high-level entity is divided into lower-level entities based on distinct characteristics. For example, an entity 'Account' can be specialized into 'SavingsAccount' and 'CurrentAccount'. Conversely, generalization merges lower-level entities into a higher-level one.
  • Aggregation: This feature allows a relationship between two entities to be treated as a single entity, enabling relationships to be formed between that relationship and another entity. For instance, if an 'Employee' works on a 'Project' and uses 'Equipment', the 'Works_On' relationship can be aggregated to associate it with the 'Equipment' entity.
  • Attribute Inheritance: In specialization/generalization hierarchies, lower-level entities inherit all attributes and relationships from the higher-level superclass entity, reducing redundancy.
  • Constraints: These include cardinality constraints (one-to-one, one-to-many, many-to-many) and participation constraints (total vs. partial participation), which define the rules governing how entities interact.
  • Weak Entities: An entity that does not have a primary key of its own and depends on the existence of an identifying 'owner' entity. It is represented by a double-bordered rectangle.

These features allow designers to capture real-world constraints more accurately, facilitating a smoother transition from conceptual design to physical database implementation.

2

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.

15 marks

Answer

The E-R diagram for the registrar's office consists of four primary entity sets and their relationships. The entities are defined as follows: Course (CourseNumber, Title, Credits, Syllabus, Prerequisites), Offering (CourseNumber, Year, Semester, SectionNumber, Timings, Classroom), Student (StudentID, Name, Program), and Instructor (InstructorID, Name, Department, Title).

The relationships are modeled as follows:

  • Course-Offering: A one-to-many relationship where one course can have multiple offerings, but an offering belongs to exactly one course.
  • Offering-Instructor: A many-to-many relationship as an offering may have multiple instructors, and an instructor may teach multiple offerings.
  • Enrollment: A many-to-many relationship between Student and Offering. The relationship set includes the attribute Grade to record the performance of the student in that specific course offering.

Assumptions and Mapping Constraints:

  • A Course is identified by its CourseNumber. Prerequisites is a multi-valued attribute of Course, representing a self-referencing relationship where a course can have multiple prerequisites.
  • Offering is a weak entity set dependent on Course, identified by the combination of CourseNumber, Year, Semester, and SectionNumber.
  • An Instructor can be associated with zero or more offerings, and an offering must have at least one instructor.
  • A Student can enroll in multiple offerings, and an offering can have many students. The Grade attribute is stored on the Enrollment relationship, which is a ternary-like association between Student, Offering, and the Grade result.
  • We assume that Timings and Classroom are simple attributes of the Offering entity.
3

Consider the following relations:

Student (snum: integer, sname: string, major: string, level: string, age: integer)

Class (name: string, meets_at: time, room: string, fid: integer)

Enrolled (snum: integer, cname: string)

Faculty (fid: integer, fname: string, deptid: integer)

The meaning of these relations is straightforward; for example, Enrolled has one record per student-class pair such that the student is enrolled in the class.

Write the following queries in SQL. No duplicates should be printed in any of the answers.

  1. Find the names of all Juniors (level = JR) who are enrolled in a class taught by I. Teach.
  2. Find the age of the oldest student who is either a History major or enrolled in a course taught by I. Teach.
  3. Find the names of all classes that either meet in room R128 or have five or more students enrolled.
  4. Find the names of all students who are enrolled in two classes that meet at the same time.
  5. Find the names of faculty members who teach in every room in which some class is taught.
  6. Find the names of faculty members for whom the combined enrollment of the courses that they teach is less than five.
  7. Print the level and the average age of students for that level, for each level.
  8. Print the level and the average age of students for that level, for all levels except JR.
15 marks

Answer

Sign in to view the complete answer paper.

4

Explain about complex integrity constraints in SQL and designing active databases.

15 marks

Answer

Sign in to view the complete answer paper.

5

Describe selection, projection, set operations, renaming and joins in relational algebra with examples.

15 marks

Answer

Sign in to view the complete answer paper.

615 marks
a

Consider the relation R on attributes (ABCDE) with functional dependencies: AB -> CDE, AC -> BDF, B -> C, C -> B, C -> D, B -> E.

i) Determine a Key for relation R.

ii) Find 3NF decomposition for R using normalization process.

8 marks

Answer

Sign in to view the complete answer paper.

b

What are the pitfalls in relational database design?

7 marks

Answer

Sign in to view the complete answer paper.

715 marks
a

Describe the two-phase locking protocol with the help of an example.

8 marks

Answer

Sign in to view the complete answer paper.

b

What are the basic properties of a transaction? Explain these properties with the help of an example?

7 marks

Answer

Sign in to view the complete answer paper.

8

Explain the following:

15 marks
a

Buffer manager

5 marks

Answer

Sign in to view the complete answer paper.

b

Composite search key

5 marks

Answer

Sign in to view the complete answer paper.

c

ISAM

5 marks

Answer

Sign in to view the complete answer paper.

About this paper

This page contains the solved question paper with answers of DATABASE MANAGEMENT SYSTEMS from JNTU for MCA 2022 III, March/April - 2022, R17.

For the question paper without answers, switch to the Question Paper tab.

Other papers in DATABASE MANAGEMENT SYSTEMS

Loading Question Papers

Fetching data from database...