Database Management and Relational Database Management System
Database Management and Relational Database Management System
Database Management and Relational Database Management System
Management System
Sheetal Shaji
1.0 INTRODUCTION
1.1. Definition
Database Management system is a set of computer programs that controls the creation,
maintenance, and the use of the database of an organization and its end users.
• The DBMS accepts requests for data from the application program and instructs
the operating system to transfer the appropriate data.
• When a DBMS is used, information systems can be changed much more easily
as the organization's information requirements change.
• New categories of data can be added to the database without disruption to the
existing system.
• Data management involves both defining structures for storing information and providing
mechanisms for manipulating the information.
• The database system must provide for the safety of the stored information, despite
system crashes or attempts at unauthorized access.
• If data are to be shared among several users, the system must avoid possible anomalous
results due to multiple users concurrently accessing the same data.
A DBMS includes four main parts: modeling language, data structure, database query language,
and transaction mechanisms:
• DBMS Engine accepts logical request from the various other DBMS subsystems,
converts them into physical equivalent, and actually accesses the database and data
dictionary as they exist on a storage device.
• Data Definition Subsystem helps user to create and maintain the data dictionary and
define the structure of the files in a database.
• Data Manipulation Subsystem helps user to add, change, and delete information in a
database and query it for valuable information. Software tools within the data manipulation
subsystem are most often the primary interface between user and the information
contained in a database. It allows user to specify its logical information requirements.
• Application Generation Subsystem contains facilities to help users to develop
transactions-intensive applications. It usually requires that user perform a detailed series
of tasks to process a transaction. It facilities easy-to-use data entry screens, programming
languages, and interfaces.
• Data Administration Subsystem helps users to manage the overall database
environment by providing facilities for backup and recovery, security management, query
optimization, concurrency control, and change management.
In relational databases, fields can be used in a number of ways (and can be of variable length),
provided that they are linked in tables. It is developed based on a database model that provides for
logical connections among files (known as tables) by including identifying KEY from one table in
another table.
Non-relational databases place information in field categories that we create so that information is
available for sorting and disseminating the way we need it. The data in a non-relational database,
however, is limited to that program and cannot be extracted and applied to a number of other
software programs, or other database files within a school or administrative system. The data can
only be "copied and pasted.“ Example: a spread sheet.
The hierarchical structure was used in early mainframe DBMS. Records’ relationships form a
treelike model. It is used primary today for storing geographic information and file systems.
6.2 Network Structure
The relational structure is the most commonly used today. It is used by mainframe, midrange and
microcomputer systems. It uses two-dimensional rows and columns to store data. The tables of
records can be connected by common key values.
• The multidimensional structure is similar to the relational model. The dimensions of the
cube looking model have data relating to elements in each cell.
• This structure gives a spreadsheet like view of data.
Data abstraction is the process of distilling data down to its essentials. In an object schema, the
abstract data model is implemented as a graph. It is achieved through several levels of
abstraction.
1. Physical level: This is the lowest level at which how data is stored is described.
2. Conceptual level: The next higher level at which what data is stored is described along
with the relationship between the data elements.
3. View level: The highest level of abstraction at which only part of the database is
described.
A data model is a conceptual representation of the data structures that are required by a database.
The goal of the data model is to make sure that all data objects required by the database are
completely and accurately represented.
The ER model is a conceptual data model that views the real world as entities and relationships.
• Entity: Entities are the principal data object about which information is to be collected.
• Strong Entity Type: An entity which exists independent of other entities is a strong entity.
• Weak entity Type: An entity type whose existence depends on another entity.
• Attributes: An attribute is a property or characteristic of an entity.
• Multi-valued attribute: Certain attributes may have more than one value for the same
instance
• Derived attribute: Some attributes could be calculated or derived from other attributes.
• Relationships: A relationship represents an association between two or more entities.
• Unary relationship is a relationship between two instances of the same entity.
• Binary relationships, the association between two entities most common in real world.
• Ternary relationship involves three entities and is used when a relationship is inadequate.
7.3.1 Figure
Strong
Weak Entity
Entity
Multi-valued
Attribute
attribute
Binary Relationship
8.1 Normalisation
A relation is in First normal form, if it does not contain any multi-valued attributes. The following is a
table given as an example:
S1 20 Kochi P1 200
S1 20 Kochi P2 300
S2 10 TVM P1 100
S3 20 Kochi P2 300
A table which has multi valued attributes, could be converted into first normal form by extending the
data in the other columns which are empty because of the multi-valued columns. Although the table
is in 1NF form, it contains redundant data. This redundancy causes update anomalies. Update
anomalies are problems that arise when information is inserted, deleted or updated.
A relation is in the second normal form if it is first normal form and every non-key attribute is fully
functionally dependent on the primary key.
Transforming a 1NF table into 2NF form:
• Identify any determinants other than the composite key and the columns they determine.
• Create and name a new table for each determinant and the unique columns it determines
• Move the determinant columns from the original table to the new table.
• Delete the column you just moved from the original table except the determinate.
• The original table may be renamed to maintain semantic meaning
S1 20 Kochi
S2 10 TVM
S3 20 Kochi
The third normal requires that all columns in a relational table are dependent only upon the primary
key. A relation is in third normal form if it is in second form and no transitive dependencies exist.
Supplier City
S1 Kochi
S2 TVM
S3 Kochi
Status City
20 Kochi
10 TVM
Advantages of 3NF form
• Facts about the status of a city can be added even though there is no supplier in that city.
• Information about parts supplied can be deleted without destroying information about
supplier or city.
9.0 REFERENCES