Dbms-Module-1 Solutions
Dbms-Module-1 Solutions
1. With neat diagram explain the component models of the DBMS and
Answer: The below diagram show the component models of the DBMS
The top part of the figure refers to the various users of the database
environment and their interfaces.
The lower part shows the internal modules of the DBMS responsible
for storage of data and processing of transactions.
The top part of Figure shows interfaces for the DBA staff, casual users,
application programmers and parametric users.
DBIT,Bangalore Page 1
DBMS-18CS53
The DBA staff works on defining the database and tuning it by making
changes to its definition using the DDL and other privileged
commands.
Casual users and persons with occasional need for information from
the database interact using the interactive query interface and
Query Compiler compiles them into the internal form. query
optimizer is concerned with the rearrangement and possible
reordering of operations, elimination of redundancies, and use of
efficient search algorithms during execution.
Application programmers write programs in host languages such as
Java, C, or C++ that are submitted to a precompiler.
The precompiler extracts DML commands from an application
program written in a host programming language. These commands
are sent to the DML compiler for compilation into object code for
database access. The rest of the program is sent to the host language
compiler. The object codes for the DML commands and the rest of the
program are linked, forming a canned transaction whose executable
code includes calls to the runtime database processor.
Canned transactions are executed repeatedly by parametric users via
PCs or mobile apps; these users simply supply the parameters to the
transactions.
DBIT,Bangalore Page 2
DBMS-18CS53
It works with the system catalog and may update it with statistics. It
also works with the stored data manager.
integrated into the working of the runtime database processor for purposes
of transaction management.
----------------------------------------------------------------------------------------------------
so any changes made in the structure of the database will not affect the
application program. this process is called program data independence.
----------------------------------------------------------------------------------------------
Answer:
Value Set: The value set specifies the set of values that may be assigned
for each individual entity. For example, we can specify the value set for
designation attribute as ( software Engg, Software Analyst, Lecture,
Assistant professor, Principal, Peon, Sweeper) etc.
Data model: Data models are used to represent the logical structure of
the database, different types of models can be used to represent the
structure of the database.
Meta data: The information about the database stored in the DBMS
catalog is called the meta-data. Meta data contains the data type, size ,
name and storage information.
DBIT,Bangalore Page 4
DBMS-18CS53
Data Redundancy: Most of the DBMS provides facilities for controlling the
data redundancy using Normalization.
Restricting unauthorized access: When multiple users access the
database some of the users are not allowed to access the database.
Providing backup and recovery: DBMS must provide the facility of backup
and recovery from the hardware and software. The backup subsystem of the
DBMS is responsible for the recovery and backup.
Providing multiple user interfaces: Since database support different type
of user so the DBMS must provide different user different interface to access
the data.
Enforcing Integrity constraints: Most of the database applications have
certain integrity constraints that must hold for the data. Example: simple
integrity constraint is the data type.
DBIT,Bangalore Page 5
DBMS-18CS53
---------------------------------------------------------------------------------------------------
5. With neat diagram explain the architecture of the typical DBMS [6
Marks]
Answer:
The below diagram shows the architecture of the typical DBMS
DBIT,Bangalore Page 6
DBMS-18CS53
-------------------------------------------------------------------------------------------------------
DBIT,Bangalore Page 7
DBMS-18CS53
Answer:
II) Data Model: Data Models is a collection of concepts that can be used
to describe the structure of the Database OR Data models define how
the logical structure of a database is modeled.
Example: Below Example shows Entity Relationship Model
DBIT,Bangalore Page 8
DBMS-18CS53
Normally, the superclass is defined first, the subclass and its related
attributes are defined next, and relationship set are then added.
Generalization:
DBIT,Bangalore Page 9
DBMS-18CS53
--------------------------------------------------------------------------------------------------------
9. What are structural constraints with relationship type? Explain with
example? [6 Marks CO-1 RBTL-1]
Answer:
DBIT,Bangalore Page 10
DBMS-18CS53
---------------------------------------------------------------------------------------------
10. Explain different type of attributes that appear in ER Model with an
example [6 Marks CO-1 RBTL-2]
Answer: There are five types of attributes: Simple, Composite, Single-
valued, Multi-valued, and Derived attribute.
1. Simple attribute:
An attribute which cannot be further subdivided into components
is a simple attribute.
Example: The roll number of a student, the id number of an
employee.
2. Composite attribute:
An attribute which can be splitted into components is a composite
attribute.
Example: The address can be further splitted into house number,
street number, city, state, country and pincode, the name can also
be splitted into first name middle name and last name.
3. Single-valued attribute:
The attribute which takes up only a single value for each entity
instance is single-valued attribute.
Example: The age of a student.
4. Multi-valued attribute:
The attribute which takes up more than a single value for each
entity instance is multi-valued attribute.
Example: Phone number of a student: Landline and mobile.
5. Derived attribute:
An attribute that can be derived from other attributes is derived
attribute.
Example: Total and average marks of a student.
DBIT,Bangalore Page 11
DBMS-18CS53
-------------------------------------------------------------------------------------------
11. Design ER Diagram for keeping track information about Bank
database taking into account at least four entities [4 Marks CO-1
RBTL-5]
Answer:
--------------------------------------------------------------------------------------------------------
12. Define the following: [10 Marks CO-1 RBTL-1]
DBIT,Bangalore Page 12
DBMS-18CS53
Role Names:The role name signifies the role that a participating entity from
the entity type plays in each relationship instance, and it helps to
explain what the relationship means.
For example, in the WORKS_FOR relationship type, EMPLOYEE plays the
role of employee or worker and DEPARTMENT plays the role of
department or employer.
DBIT,Bangalore Page 13
DBMS-18CS53
13. What are roles and responsibility of DBA and Database Designers [4
Marks CO-1 RBTL-1]
Answer:
DBA: DBA stands for Database Administrators, primary job is to ensure that
data is available, easily accessible and protected from loss and
corruption. DBA is also responsible for software installation and
maintenance, Data transformation and loading, database backup and
recovery,providing the authentication and monitoring the performance
of the database users.
DBIT,Bangalore Page 14
DBMS-18CS53
DBIT,Bangalore Page 15
DBMS-18CS53
DBIT,Bangalore Page 16
DBMS-18CS53
DBIT,Bangalore Page 17