0% found this document useful (0 votes)
3 views

DBMS SOLVED QB

The document is a question bank for the Database Management System course, covering key concepts such as data, databases, DBMS characteristics, advantages, and architecture. It includes topics like data models, entity-relationship models, integrity constraints, and normalization, providing definitions, explanations, and examples. Additionally, it outlines responsibilities of database administrators and various types of database users.

Uploaded by

mr.op7744
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)
3 views

DBMS SOLVED QB

The document is a question bank for the Database Management System course, covering key concepts such as data, databases, DBMS characteristics, advantages, and architecture. It includes topics like data models, entity-relationship models, integrity constraints, and normalization, providing definitions, explanations, and examples. Additionally, it outlines responsibilities of database administrators and various types of database users.

Uploaded by

mr.op7744
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/ 19

Course Name: Database Management System

Course Code: 17YCM402/ 17YCF402/ 17YCT402/ 17YCS402


QUESTION BANK for ESE Examination
____________________________________________________________________________ UNIT -1
1. Define term Data.
Data can be structured, organized, and stored in databases, spreadsheets, or other data storage systems, or it
can be unstructured and exist in the form of documents, emails, social media posts, or multimedia files.
2. Define term Database
A database is a structured collection of data organized and stored in a way that allows for efficient storage,
retrieval, manipulation, and management of information. It serves as a central repository where data is
systematically organized, making it easy to access, update, and analyze.
3) Write short note on DBMS. (Database Management system) 4) List the characteristics of DBMS.
Database Management System (DBMS) is a software system that provides an interface for managing databases.
It acts as an intermediary between the users and the actual database, allowing users to interact with the data
without having to deal with the complexities of data storage and retrieval.
Data Definition
Data Manipulation
Data Security
Data Integrity
Data Abstraction
5) List various advantages of DBMS.
Data Centralization
Data Sharing and Collaboration
Data Integrity and Security
Efficient Data Access and Retrieval
Data Consistency and Standardization
Data Scalability
Data Backup and Recover
6)Describe three level architecture of DBMS. Explain how it is useful for achieving data independence.

Different users need different views of the same data.


The approach in which a particular user needs to see the data may change over time.
All users should be able to access the same data according to their requirements.
DBA should be able to change the conceptual structure of the database without affecting the user's
Internal structure of the database should be unaffected by changes to physical aspects of the storage.
7)Explain abstraction of DBMS.
Abstraction in the context of Database Management Systems (DBMS) refers to the process of simplifying
complex details and providing a high-level representation of the database system.
DBMS provides different levels of abstraction to facilitate efficient and meaningful interaction with the
database. These levels of abstraction include:
Physical Data Abstraction
Logical Data Abstraction
View Data Abstraction
8)Draw and list different components of Database System structure.
+----------------------------------+
| Database System |
+----------------------------------+
| |
| Application Programs |
| |
+----------------------------------+
| |
| Database Management |
| System (DBMS) |
| |
+----------------------------------+
| |
| Database Components |
| |
+----------------------------------+
| |
| Data Storage and |
| Management |
| |
+----------------------------------+
The different components of a Database System structure are
Application Programs
Database Management System (DBMS)
Database Components
Data Storage and Management
9)List various types of database users.
End Users
Database Administrators (DBAs)
Application Developers
Database Designers
Data Analysts
Executives and Managers

10)List responsibilities of DBA

Database Installation and Configuration


Database Design and Schema Definition
Security Management
Backup and Recovery
Performance Monitoring and Tuning
Capacity Planning
Disaster Recovery Planning
11)Draw and discuss Database Model.
Hierarchical Model
Network Model
Relational Model
Object-Oriented Model
Document Model
Graph Model
12)List the different types of Data Models. Explain ay Two
Hierarchical Model
Network Model
Relational Model
Object-Oriented Model
Document Model
Graph Model
1)Hierarchical Data Model:
The hierarchical data model organizes data in a tree-like structure with a parent-child relationship. It represents
data using a series of nested records or segments. Each parent record can have multiple child records, but each
child record can have only one parent
2)Relational Data Model:
The relational data model is the most widely used data model. It organizes data into tables, with each table
representing an entity, and the relationships between entities are defined using primary keys and foreign keys.
13)Define term entity and entity Set.
In the context of database management, an entity refers to a distinct object, concept, or thing that is
identifiable and has attributes or properties. An entity represents a real-world object or an abstraction of
something that is relevant to the database.

Entities can be tangible objects, such as a customer, product, or employee, or intangible concepts, such as an
order, transaction, or reservation. Each entity is uniquely identifiable and can be represented by a set of
attributes that describe its characteristics.
14)Discuss term E-R Model.
The Entity-Relationship (E-R) model is a conceptual data model used to represent the structure of a database. It
provides a graphical representation of entities, their attributes, and the relationships between them
The E-R model consists of three main components:
Entities
Relationships
Attributes
15)Differentiate between Strong Entity and Weak Entity.
Strong Entity:
A strong entity is an entity that can exist independently and has its own unique identifier or primary key. It has
sufficient attributes to be uniquely identified within the entity set. Strong entities are represented by regular
rectangles in the E-R diagram.
Weak Entity:
A weak entity, on the other hand, is an entity that depends on another entity for its existence and cannot be
uniquely identified by its own attributes alone. It requires a relationship with a strong entity, known as the
identifying or owner entity, to give it meaning and uniqueness.
16)Explain Different types of attributes of an entity with the help of example.
Simple Attribute:
A simple attribute is an attribute that cannot be divided into smaller components. It represents a single value
associated with an entity. For example, consider a "Person" entity with attributes like "Name," "Age," and
"Gender." Each of these attributes represents a single value and can be classified as simple attributes.
Composite Attribute:
A composite attribute is an attribute that can be divided into multiple sub-attributes or components. It
represents a collection of related values. For instance, consider a "Address" attribute for a "Customer" entity,
which consists of sub-attributes like "Street," "City," "State," and "Zip Code." The composite attribute "Address"
is composed of several sub-attributes, each representing a distinct value.

Derived Attribute:
A derived attribute is an attribute that can be calculated or derived from other attributes or entities. It does not
have a direct value stored in the database but can be derived using formulas, expressions, or algorithms. For
example, consider a "Total Price" attribute for an "Order" entity. The total price can be derived by multiplying
the quantity of items with their individual prices.

Multi-valued Attribute:
A multi-valued attribute is an attribute that can have multiple values for a single entity occurrence. It
represents a set of values instead of a single value. For instance, consider a "Skills" attribute for an "Employee"
entity. An employee can possess multiple skills, such as programming, leadership, and communication. The
"Skills" attribute can hold multiple values for each employee.

Null Attribute:
A null attribute is an attribute that does not have a value assigned to it. It represents missing or unknown
information for an entity. For example, in a "Product" entity, the "Manufacturing Date" attribute may be null for
a product if the manufacturing date is not known or not applicable.

Key Attribute:
A key attribute is an attribute that uniquely identifies each entity occurrence within an entity set. It helps in
uniquely identifying and distinguishing one entity from another. For example, in a "Student" entity, the
"Student ID" attribute can serve as the key attribute, ensuring that each student has a unique identifier
17)Define Relationship Set. Give various constraints of relationship.
In the Entity-Relationship (E-R) model, a relationship set represents the collection or group of relationships
between entities.
Many-to-Many (M:N): In a many-to-many relationship, each instance of one entity can be associated with
multiple instances of another entity, and vice versa. For example, a "Student" entity may have a many-to-many
relationship with a "Course" entity, where each student can enroll in multiple courses, and each course can
have multiple enrolled students. To represent a many-to-many relationship, an intermediate entity called an
associative entity or junction table is often introduced.
18)Draw E-R Diagram for University database consisting 4 entities. 1) Student 2) Department 3) Class 4) Faculty
+-----------+ +------------+
| Department| | Faculty |
+-----------+ +------------+
| | | |
| | | |
| | +--------------+
| +---------| Class |
| +--------------+
|
|
+-------+
|Student|
+-------+

The "Student" entity represents the students enrolled in the university. It may have attributes like student ID,
name, address, and date of birth.

The "Department" entity represents the different academic departments within the university. It may have
attributes like department ID, name, and location.

The "Class" entity represents the classes or courses offered by the university. It may have attributes like class ID,
title, and schedule.

The "Faculty" entity represents the faculty members working in the university. It may have attributes like
faculty ID, name, specialization, and contact information

19)Construct an E-R diagram for a car-insurance company whose customers own one or more cars each. Each
car has associated with it zero to any number of recorded accidents.

+-----------+ +------------+
| Customer | | Car |
+-----------+ +------------+
| | | |
| | | |
| | +--------------+
| +-------- | Accident |
| +--------------+
|
|
+-------+
|Insurance|
+-------+
In this diagram:

The "Customer" entity represents the customers of the car-insurance company. It may have attributes like
customer ID, name, address, and contact information.

The "Car" entity represents the cars owned by the customers. It may have attributes like car ID, make, model,
year, and other relevant information about the car.

The "Accident" entity represents the recorded accidents associated with each car. It may have attributes like
accident ID, date, location, and details of the accident.
20)List and Explain E-R Diagram Components.
In an Entity-Relationship (E-R) diagram, various components are used to represent and define the structure of a
database. These components help visualize the entities, relationships, attributes, and constraints within the
database. Here are the key components of an E-R diagram:

Entity:
An entity represents a distinct object, concept, or thing in the real world that is relevant to the database. It is
represented by a rectangle in the diagram and is labeled with the entity name

Relationship:
A relationship depicts the association or connection between entities. It represents the meaningful interactions
or dependencies between entities in the database.

Attributes:
Attributes represent the characteristics or properties of an entity. They provide detailed information about the
entities within the database

Primary Key:
The primary key is an attribute or a combination of attributes that uniquely identify each instance or
occurrence of an entity
Cardinality:
Cardinality describes the number of instances or occurrences of one entity that can be associated with another
entity through a relationship

Participation Constraint:
Participation constraint defines whether an entity's participation in a relationship is mandatory or optional.

Weak Entity:
A weak entity is an entity that depends on another entity for its existence and cannot be uniquely identified by
its own attributes alone.

UNIT-2
1.Define term Relational Model.
The relational model is a conceptual framework used in database management systems (DBMS) to organize and
structure data.
2.List types of Keys in DBMS.
Primary Key
Foreign Key
Candidate Key
Composite Key
Alternate Key
3.Define concepts of views along with its operations.
A view is a virtual table that is derived from the data stored in one or more underlying tables. It does not physically
store data but presents a tailored representation of the data to users or applications.
4.Explain advantages of Views.
Data Security: Views provide an additional layer of security by allowing you to restrict access to sensitive data.
Simplified Data Access: Views simplify data access by presenting a tailored and simplified view of the data.
Data Abstraction: Views provide a level of data abstraction by hiding the underlying complexity of the database
structure.
5.Explain the concept of Functional Dependencies.
functional dependencies are a concept used to describe the relationship between attributes or sets of attributes
within a relation (table).
State and explain Codd’s norms for DBMS.
The logical data in a database must be independent of its user's view (application). Any change in logical data must
not affect the applications using it. For example, if two tables are merged or one is split into two different tables,
there should be no impact or change on the user application.
6.Explain all types of Integrity with the help of example.
Entity Integrity:
Entity integrity ensures that each row or record in a table has a unique identifier, typically defined by a
primary key
Referential Integrity:
Referential integrity ensures that relationships between tables are maintained correctly.
Domain Integrity:
Domain integrity ensures that data entered into a column adheres to the defined domain or data type constraints.
7.Explain the term “Referential Integrity” and its relation with foreign key.
Referential integrity ensures that the values stored in a foreign key column of one table (the referencing table)
correspond to the values of the primary key column in another table
8.Write short note on Integrity constraints.
Integrity constraints are rules defined in a database management system (DBMS) that enforce the accuracy,
consistency, and validity of data stored in a database. These constraints help maintain data integrity by preventing the
entry of incorrect or inconsistent data.
9.Write short note on:
-Domain Integrity
Domain integrity is an important aspect of data integrity in a database management system (DBMS). It ensures
that data stored in a database adheres to the defined rules and constraints for each attribute or column, including
data types, formats, and allowable values.
-Referential Integrity and its relation with Foreign Key.
Referential integrity is a concept in database management systems (DBMS) that ensures the consistency and
correctness of relationships between tables. It is closely related to the use of foreign keys.
10.Define term Data Integrity.
Data integrity refers to the accuracy, consistency, and reliability of data stored in a database. It ensures that the
data is complete, valid, and reliable throughout its lifecycle, from creation to storage and retrieval.
11.Write short note on following:
Super Key
In a relational database, a superkey is a set of one or more attributes (columns) that can uniquely identify a tuple
(row) within a table. A superkey contains enough information to uniquely identify each record in a table.
Primary Key
A primary key is a unique identifier for each record (tuple) in a relational database table. It is a column or set of
columns that uniquely identifies each row within a table.
Candidate Key
a candidate key is a set of one or more attributes (columns) that can uniquely identify a tuple (row) within a
table. Similar to a primary key, a candidate key is used to ensure the uniqueness of records. However, unlike a
primary key, a candidate key is not selected as the main identifier for the table.
12.Explain concept of functional Dependency.
Functional dependency is a fundamental concept in database management systems (DBMS) that describes the
relationship between attributes or columns in a table. It represents a dependency or association between the values
of one or more attributes and the values of another attribute in the same table.
13.State and Explain Armstrong’s Axioms and its properties.
Armstrong's axioms, also known as Armstrong's rules or inference rules, are a set of logical rules used in the field of
relational database theory to infer functional dependencies. They were introduced by William W. Armstrong and are
widely used for reasoning about dependencies in a relational schema.
14.Define term Decomposition.
Decomposition, in the context of database management systems, refers to the process of breaking down a single
relation (table) into multiple smaller relations. It involves dividing the attributes of a relation and distributing them
among the resulting decomposed relations.
15.List the properties of Decomposition. Explain loss less join with the help of Example.
Lossless Join: A decomposition is said to have the lossless join property if the original relation can be reconstructed by
joining the decomposed relations. In other words, no information is lost during the decomposition process. The
lossless join property ensures that the decomposed relations contain all the information needed to reconstruct the
original relation.
16.Discuss the term Lossless-Join decomposition.
Lossless-join decomposition is a property that ensures the preservation of all functional dependencies and the ability
to reconstruct the original relation by joining the decomposed relations without any loss of information
17.Define term Normalization. State and explain 2NF and 3NF.
Normalization is a process in database design that organizes a database schema into a set of normal forms to
eliminate data redundancy, update anomalies, and ensure data integrity.
Second Normal Form (2NF):
2NF is achieved when a relation is in 1NF (First Normal Form) and there are no partial dependencies.
Third Normal Form (3NF):
3NF is achieved when a relation is in 2NF and there are no transitive dependencies.
18.State the need of Normalization in DBMS.
Normalization helps maintain data integrity by eliminating data redundancy and inconsistencies. Redundant data can
lead to anomalies and inconsistencies, such as update anomalies (where updating data in one place leads to
inconsistencies in other places).
19.Explain 1NF.
First Normal Form (1NF) is the basic level of normalization in database design. It sets the foundation for organizing
data in a structured and consistent manner.
20.Explain 2NF.
Second Normal Form (2NF) is a higher level of normalization in database design that builds upon the concepts of First
Normal Form (1NF). It addresses the issue of partial dependencies that can occur when a relation has a composite
primary key. To achieve 2NF
21.State and Explain 3 NF.
Third Normal Form (3NF) is a further level of normalization in database design that builds upon the concepts of
First Normal Form (1NF) and Second Normal Form (2NF). It addresses the issue of transitive dependencies that
can exist within a relation.
22.Explain BCNF (Boyce Codd Normal Form).
BCNF (Boyce-Codd Normal Form) is a higher level of normalization in database design that addresses the issue of
functional dependencies and eliminates all types of anomalies. It is an extension of the Third Normal Form (3NF) and
ensures that a relation is free from all non-trivial functional dependencies.
23.Explain 4NF.
Fourth Normal Form (4NF) is a further level of normalization in database design that builds upon the concepts of First
Normal Form (1NF), Second Normal Form (2NF), and Third Normal Form (3NF). It aims to address the issue of multi-
valued dependencies within a relation.
24.Explain 5NF and Join Dependency.
Fifth Normal Form (5NF), also known as Project-Join Normal Form (PJNF), is a higher level of normalization in database
design that aims to address the issue of join dependencies. 5NF builds upon the concepts of First Normal Form (1NF),
Second Normal Form (2NF), Third Normal Form (3NF), and Fourth Normal Form (4NF).

UNIT-3
1.Define term query.
In the context of databases, a query refers to a request or instruction to retrieve specific information or perform
operations on a database. It is a means of communication between a user or an application and the database
management system (DBMS). A query allows users to interact with the database by retrieving, modifying, or
manipulating data based on specified criteria.
2.Explain role of SQL with the help of example.
SQL (Structured Query Language) plays a critical role in interacting with databases and managing data. It is a
standard language used to communicate with relational database management systems (RDBMS) such as MySQL,
PostgreSQL, Oracle, and SQL Server. SQL provides a set of commands and syntax for performing various operations
on databases, including data retrieval, modification, and administration.
3.Discuss various MySQL data types.
Numeric Types:
INT: Used to store whole numbers. It can have a specified length.
DECIMAL: Used to store fixed-point decimal numbers. It requires a precision and scale value to define the total
number of digits and the number of decimal places.
FLOAT, DOUBLE: Used to store floating-point numbers with single or double precision.
4.Explain DDL commands.
DDL stands for Data Definition Language, and it consists of a set of SQL commands used to define and manage the
structure of a database and its objects. DDL commands are responsible for creating, altering, and dropping
database objects such as tables, indexes, views, and constraints.
5.Write short note on DML Commands.
DML stands for Data Manipulation Language, and it consists of a set of SQL commands used to manipulate and
query data within a database. DML commands are responsible for inserting, updating, deleting, and retrieving data
from tables. Here are some commonly used DML commands in SQL:
SELECT
INSERT
UPDATE
DELETE
6.Differentiate between Data Definition Language and Data Manipulation Language.

7.List various data Definition statements in SQL.


CREATE DATABASE: Creates a new database.
CREATE TABLE: Creates a new table with specified columns, data types, and constraints.
ALTER TABLE: Modifies the structure of an existing table, such as adding or dropping columns, modifying column
definitions, or adding constraints.
DROP TABLE: Removes an existing table and all its data from the database.
Explain CREATE command with the help of example.
8.Describe DROP TABLE command of SQL with both the options CASCADE AND RESTRICT.
CASCADE:
When the CASCADE option is used with the DROP TABLE command, it not only removes the specified table but also
automatically drops any other database objects that depend on that table.
RESTRICT:
When the RESTRICT option is used with the DROP TABLE command, it ensures that the table is only dropped if
there are no dependent objects associated with it. If any dependent objects exist, the DROP TABLE operation is
restricted, and an error is returned.

9.Explain RENAME Command with the help of Example.


The RENAME command in SQL is used to rename an existing database object, such as a table, column, index, or
constraint. It allows you to change the name of the object without altering its structure or data. The RENAME
command is particularly useful when you need to update the name of an object to better reflect its purpose or to
adhere to naming conventions.
11.Explain TRUNCATE Command with the help of Example.
Justify “Why Domain Integrity is important in Database?”
RUNCATE is a command used in SQL to remove all rows from a table, effectively deleting all data stored in the
table. Unlike the DELETE command, which removes individual rows, the TRUNCATE command removes all rows
at once, resulting in faster execution and less transaction logging.
12) Explain the purpose of Foreign Key.
The purpose of a foreign key in a relational database is to establish a relationship between two tables based on a
common attribute. It ensures referential integrity and enforces the relationship between the tables.
13.Explain the concept of view along with its operations.
In the context of databases, a view is a virtual table that is derived from the data stored in one or more
underlying tables. It is a logical representation of data that can be queried and manipulated like a regular table.
The concept of a view allows users to customize and simplify their interaction with the database by providing a
tailored perspective of the data.
14.List types of Views.
Simple Views
Complex views
Materialized Views
Indexed Views
Updatable Views
15.List advantages of Views.
Data Security
Simplified Data Access
Data Abstraction
Data Integrity
Simplified Data Modifications
16.Explain ‘SELECT’ CLAUSE. Give its syntax.
The SELECT clause is a fundamental part of the SQL (Structured Query Language) that allows you to retrieve
data from a database table. It is used to specify the columns or expressions that you want to include in the
query result.
SELECT column1, column2, ...
FROM table_name
[WHERE condition]
[GROUP BY column1, column2, ...]
[HAVING condition]
[ORDER BY column1, column2, ...];
17.Explain ‘ORDER BY CLAUSE’.
The ORDER BY clause is used in SQL to sort the result set of a query based on one or more columns. It allows you to
specify the sorting order, whether ascending or descending, for the returned rows. The ORDER BY clause is typically
used in conjunction with the SELECT statement to control the presentation of the query results.
18.Define term Aggregate Function.
An aggregate function, in the context of databases and SQL (Structured Query Language), is a function that
operates on a set of rows and returns a single value as the result. It performs a calculation or summarization on a
column or expression across multiple rows and produces a consolidated output.
19.Discuss term Cartesian product.
the Cartesian product is a fundamental operation used to combine two or more tables to create a new table. It
results in a new table that contains all possible combinations of rows from the participating tables.
20.What is Natural Join? Give its syntax.
The Natural Join is a type of join operation in SQL that combines two tables based on columns with the same
name and data type. It automatically matches and joins the rows from the participating tables based on the
common column names, eliminating the need to explicitly specify the join condition.
SELECT *
FROM table1
NATURAL JOIN table2;
21.Explain various types of Outer Join Operations with the help of Example.
n SQL, there are three types of outer join operations: LEFT JOIN, RIGHT JOIN, and FULL JOIN. These operations
allow you to combine tables and retrieve unmatched rows from one or both tables based on a specified condition.

UNIT-4
Define term stored Procedures.
A stored procedure is a named set of SQL statements that are stored in a database. It is a pre-compiled
collection of SQL queries, control statements, and procedural logic, which can be executed repeatedly by
invoking its name. Stored procedures are typically used to encapsulate frequently used or complex SQL
operations and provide a convenient way to execute them.

List benefits of Stored Procedures.


Modularity and Code Organization: Stored procedures allow for modular code development. By encapsulating database
operations within procedures, you can organize and structure your codebase, making it more maintainable and
readable.
Code Reusability: Stored procedures can be shared and reused by multiple applications. Instead of writing the
same SQL logic in different parts of the application

Describe term Trigger. Explain trigger with example.


a trigger is a special type of stored procedure that is automatically executed in response to certain events or
actions occurring within a database. Triggers are used to enforce business rules, maintain data integrity, and
automate actions or calculations based on specific conditions.

Explain embedded SQL.


Embedded SQL refers to the integration of SQL statements within a high-level programming language code. It
allows developers to combine the power of SQL for database operations with the flexibility and functionality of
a programming language. Embedded SQL enables developers to interact with a database directly from within
their application code, making it easier to retrieve, manipulate, and manage data.

Explain dynamic SQL.


Dynamic SQL refers to the generation and execution of SQL statements dynamically at runtime, rather than
being hardcoded in the program. It allows developers to construct SQL statements on the fly based on varying
conditions or user inputs.

Differentiate between static and Dynamic SQL.


Explain term Transaction Processing in DBMS.
Transaction processing in DBMS (Database Management System) refers to the management and execution of
database transactions. A transaction is a logical unit of work that consists of one or more database operations
(such as reads, writes, or updates) that need to be executed as a single, indivisible unit.

Explain detailed architecture of Transaction Management.


Discuss the possible causes of Transaction Failure.
System Failure:
Hardware or software failures, such as power outages, network failures, or crashes, can lead to transaction failure.
If the system fails before a transaction is committed, the changes made by the transaction may be lost.
Constraint Violation:
Transactions can fail if they violate integrity constraints defined on the database.
Deadlocks:
Deadlocks occur when two or more transactions are waiting for resources that are held by each other.
If a transaction is involved in a deadlock situation, it cannot proceed, resulting in transaction failure.

Explain the significance of ACID Properties..


ACID is an acronym that stands for Atomicity, Consistency, Isolation, and Durability. These properties are fundamental in
ensuring the reliability and integrity of transactions in a Database Management System (DBMS).
Atomicity
Consistency
Isolation
Durability

Define term View.


In the context of a database, a view is a virtual table that is derived from the data stored in one or more
underlying tables. It does not contain any physical data itself but represents a query result or a subset of data
from the underlying tables.

Explain the transaction processing with the help of state Diagram.


Transaction processing refers to the management and execution of database transactions in a Database
Management System (DBMS). It involves a series of steps that ensure the reliability, consistency, and durability
of transactions.
Write short note on: Commit and rollback.
Commit and rollback are two essential operations in transaction processing within a database management
system (DBMS). They play a crucial role in ensuring the integrity and reliability of data.

Define Serializability. Explain conflict and View Serializability.


Serializability is a concept in database systems that ensures the correctness and consistency of concurrent
transactions. It determines whether the execution of concurrent transactions produces the same results as if
the transactions were executed serially, one after the other. In other words, serializability guarantees that the
concurrent execution of transactions is equivalent to some sequential order of executing those transactions.

UNIT-5
Define term Concurrency Control. Explain the stamp based Concurrency control.
Concurrency control is a fundamental aspect of database management systems (DBMS) that ensures the
correct and consistent execution of concurrent transactions. It manages the simultaneous access to shared
data by multiple transactions, preventing conflicts and maintaining data integrity. Concurrency control
techniques aim to provide efficient and coordinated access to the database while ensuring isolation and
correctness of transactions.

Explain various problems of Concurrent Executions.


Concurrent execution of transactions in a database system can lead to several problems that can impact the
correctness, consistency, and reliability of the data. Here are some of the common problems that can arise in
concurrent executions:
Lost Updates
Dirty Reads
Inconsistent Analysis
Unrepeatable Reads

Explain Concept of Locking. Also discuss the types of Locks.


Locking is a concurrency control mechanism used in database systems to manage concurrent access to
shared resources, such as data items or database records. It ensures that only one transaction can access or
modify a resource at a time, preventing conflicts and maintaining data integrity

Explain two phase locking protocol and its disadvantages.


The 2PL protocol ensures that conflicting operations from concurrent transactions are serialized by ensuring
that no transaction reads or writes a data item that is locked by another transaction. It guarantees
serializability, meaning that the execution of concurrent transactions is equivalent to some serial order of
their operations.

Disadvantages of the Two-Phase Locking protocol include:


Deadlock Possibility:
Locking Overhead:

Define term Deadlock. Explain how Deadlock detection and prevention is done.
Deadlock is a situation in concurrent systems where two or more processes or transactions are unable to
proceed because each is waiting for the other to release resources that it holds, resulting in a circular
dependency. In other words, it is a state where multiple processes are stuck and unable to continue
execution, leading to a system deadlock.

Explain time stamp based concurrency Control.


Timestamp-based concurrency control is a technique used in database systems to manage concurrent access
to shared resources and ensure transaction serializability. It uses a timestamp mechanism to assign unique
timestamps to transactions and data items, enabling the system to make decisions based on the order of
transactions.

List down all possible Recovery Methods.


Undo/Redo Logging:
In this method, transaction activities are logged in a sequential order using undo and redo logs.
Undo logs record the old values of data items before they are modified, enabling the system to roll back
transactions during recovery.
Checkpointing:
Checkpointing involves periodically creating a checkpoint in the system, which is a consistent state of the
database.
During recovery, the system can start from the latest checkpoint to minimize the number of transShadow
Paging:
Shadow paging is a recovery technique that involves maintaining a separate copy of the entire database,
called a shadow page.
Changes made by transactions are applied to the shadow page, and once the transaction commits, the
shadow page becomes the new database state.actions that need to be undone or redone.

Explain Log based Recovery Techniques.


Log-based recovery techniques are used in database systems to ensure data consistency and recover from
system failures. These techniques rely on a transaction log, which is a sequential record of all changes made
to the database. The log contains information that allows the system to undo or redo transactions during the
recovery process.

List the operations to be performed by the system when a checkpoint is to be taken.


Flush Dirty Pages:
Write Checkpoint Record:
Update Transaction Tables:
Update Dirty Page Table:
Update Checkpoint Information:

What does the recovery system do if there is a crash?


When a crash occurs in a database system, the recovery system is responsible for bringing the database back
to a consistent state and ensuring the durability of the transactions.
The recovery system's primary goal is to restore the database to a consistent state and preserve the integrity
of the transactions. By analyzing the transaction log, performing redo and undo operations, and potentially
re-executing transactions, the recovery system ensures that the database recovers from the crash and
maintains its correctness and durability.

Explain shadow Paging with Proper Example.


Shadow paging is a technique used in database systems for implementing transactional consistency and
efficient crash recovery. It involves maintaining a shadow copy or snapshot of the database during
transaction execution and committing the changes to the actual database only when the transaction
successfully completes

Explain query Optimization with respect to SQL databases.


Query optimization is a crucial aspect of SQL databases that aims to enhance the performance and efficiency
of SQL queries. It involves the process of analyzing and transforming SQL queries to generate an optimized
execution plan that retrieves the desired results in the most efficient way possible. The goal is to minimize
the query's execution time, reduce resource utilization, and optimize the use of indexes and join operations.

Define term Database Backup. Why Database backup is needed? Explain types of database backup?
Database backup refers to the process of creating a copy or snapshot of a database's data and storing it in a
separate location or storage medium. It is an essential practice in database management to safeguard
against data loss, system failures, disasters, or human errors. The database backup ensures that a recent and
consistent copy of the data is available for recovery purposes.

Define term Recovery. Explain types of Recovery (forward and Backward Recovery).
Recovery in the context of database management refers to the process of restoring a database to a
consistent and correct state after a failure or error. It involves recovering lost or damaged data and ensuring
the integrity and availability of the database.
Types of Recovery:
Forward Recovery:
Backward Recovery

Explain different Database architectures.


Centralized Database Architecture:
In a centralized database architecture, all data is stored and managed in a single central location, typically on
a dedicated server.
Client-Server Database Architecture:
In a client-server database architecture, the database system is divided into two main components: the
client and the server.
Distributed Database Architecture:
In a distributed database architecture, data is distributed across multiple nodes or servers, which are
geographically dispersed.

Draw and explain all parallel database Architectures.


Shared Memory Architecture:
In a shared memory architecture, multiple processors or cores share a common memory space.
Shared Disk Architecture:
In a shared disk architecture, multiple processors or nodes share a common storage system or disk.
Shared Nothing Architecture:
In a shared nothing architecture, each processor or node has its own dedicated memory and disk storage.
Hybrid Architecture:
Hybrid architectures combine elements of shared memory, shared disk, and shared nothing architectures to
leverage their respective strengths.

Explain Architecture of distributed Databases.


The architecture of distributed databases refers to how data is distributed, stored, and managed across
multiple nodes or servers in a distributed environment. It involves various components and mechanisms to
ensure data consistency, availability, and scalability.

List advantages of Distributed Database systems.


Improved Performance and Scalability:
Increased Availability and Fault Tolerance:
Enhanced Data Consistency and Integrity:
Geographical Distribution and Data Localization:
Better Load Balancing and Resource Utilization:

Explain Data Replication and Data Fragmentation in Distributed Data Storage.


Data Replication in Distributed Data Storage:
Data replication refers to the process of creating and maintaining multiple copies of data across different
nodes or servers in a distributed database system. Each copy of the data is known as a replica. Replication is
used to improve data availability, fault tolerance, and performance in distributed environments.

Differentiate between Horizontal and Vertical Fragmentation.


Explain major objectives of Distributed Database Design.
Data Distribution: The primary objective is to distribute the data across multiple nodes or servers in a way
that maximizes performance and availability.
Transparency: The design should aim to provide transparency to the users and applications accessing the
distributed database.
Performance Optimization: Distributed database design focuses on optimizing the performance
Fault Tolerance and Reliability: The design should ensure high availability and fault tolerance of the
distributed database system.data access and query processing.

List and explain the advantages of NoSQL databases.


Scalability: NoSQL databases are designed to scale horizontally, allowing them to handle large amounts of
data and high traffic loads.
Flexibility in Data Models: Unlike relational databases that follow a fixed schema, NoSQL databases offer
flexible data models.
High Performance: NoSQL databases are optimized for performance.
Schema-less Design: NoSQL databases do not enforce a predefined schema, allowing for dynamic and
evolving data structures.

Differentiate between SQL and No SQL Databases.


Write short note on Internet Database.
An internet database refers to a database system that is accessible over the internet. It allows users to store,
manage, and retrieve data through web-based applications or interfaces.

Write short note on Mobile Database. Also state the functionality required for Mobile Database.
A mobile database refers to a database system specifically designed to run on mobile devices such as
smartphones, tablets, and other portable devices. It enables users to store, retrieve, and manage data locally
on their mobile devices.

Write short note on Cloud Database.


A cloud database refers to a database system that is hosted and operated on cloud computing platforms. It
leverages the infrastructure and resources provided by cloud service providers to store, manage, and
process data.

List various benefits of Mobile cloud computing.


Increased Storage Capacity
Enhanced Processing Power
Improved Battery Life
Seamless Data Synchronization:
Anytime, Anywhere Access

Differentiate between MongoDB and RDBMS.

You might also like