Mis - Unit Ii
Mis - Unit Ii
A database is a collection of related data which represents some aspect of the real world. A
database system is designed to be built and populated with data for a certain task.
What is DBMS?
Database Management System (DBMS) is a software for storing and retrieving users' data
while considering appropriate security measures. It consists of a group of programs which
manipulate the database. The DBMS accepts the request for data from an application and
instructs the operating system to provide the specific data. In large systems, a DBMS helps users
and other third-party software to store and retrieve data.
DBMS allows users to create their own databases as per their requirement. The term “DBMS”
includes the user of the database and other application programs. It provides an interface
between the data and the software application.
Advantages of DBMS
Cost of Hardware and Software of a DBMS is quite high which increases the budget of
your organization.
Most database management systems are often complex systems, so the training for users
to use the DBMS is required.
In some organizations, all data is integrated into a single database which can be damaged
because of electric failure or database is corrupted on the storage media
Use of the same program at a time by many users sometimes lead to the loss of some
data.
DBMS can't perform sophisticated calculations
2. People:
The people involved with data base system can be divided into two groups. Those who use
information provided by the system and those who design, develop, and manage the system
itself. If a data base system is to be of value to the organisation, it is imperative that it be
designed to support the needs of information users.
Those people responsible for the design, development and administration of data base systems
are often referred to as data base administrators. The position of data base administrator is highly
challenging and should be a high level managerial position.
Data base manager must possess well developed skills in both technical and managerial aspects
of information management, because they are the primary liaison between, the community of
users and the systems, development staff.
The personnel responsible for developing data base systems are information analysts or data base
analysts. Information analysts work closely with users of information to carefully define
information requirements and to structure these requirements into a logical form. Data base
analysts use data base technology to design systems satisfying those requirements.
3. Data Base Planning & Design Technique:
Since data base systems involve people from all parts of the organisation with a variety of
information needs, the development and operation of data base systems must be very carefully
planned and managed. The data bases themselves must be carefully designed to provide efficient
excess to information required by the various users.
The first step in converting to a data base approach should be the development of:
(1) A master plan that specifies in general terms the various applications and data bases to be
included in the overall system and
(2) A schedule for detailed design and implementation of these applications and data bases.
Detailed data base design consists of three major phases: information requirements analysis,
logical design, and physical design. Information requirements analysis is work done with users to
define information needs. Logical design is the development of schema and sub-schema
definitions. Physical design establishes exactly how the data will be organised and stored on the
storage devices.
Organizations produce and gather data as they operate. Contained in a database, data is typically
organized to model relevant aspects of reality in a way that supports processes requiring this
information. Knowing how this can be managed effectively is vital to any organization.
What is a Database Management System (or DBMS)?
Organizations employ Database Management Systems (or DBMS) to help them effectively
manage their data and derive relevant information out of it. A DBMS is a technology tool that
directly supports data management. It is a package designed to define, manipulate, and manage
data in a database.
Some general functions of a DBMS:
Designed to allow the definition, creation, querying, update, and administration of
databases
Define rules to validate the data and relieve users of framing programs for data
maintenance
Convert an existing database, or archive a large and growing one
Run business applications, which perform the tasks of managing business processes,
interacting with end-users and other applications, to capture and analyze data
Some well-known DBMSs are Microsoft SQL Server, Microsoft Access, Oracle, SAP, and
others.
Components of DBMS
DBMS have several components, each performing very significant tasks in the database
management system environment. Below is a list of components within the database and its
environment.
Software
This is the set of programs used to control and manage the overall database. This includes the
DBMS software itself, the Operating System, the network software being used to share the data
among users, and the application programs used to access data in the DBMS.
Hardware
Consists of a set of physical electronic devices such as computers, I/O devices, storage devices,
etc., this provides the interface between computers and the real world systems.
Data
DBMS exists to collect, store, process and access data, the most important component. The
database contains both the actual or operational data and the metadata.
Procedures
These are the instructions and rules that assist on how to use the DBMS, and in designing and
running the database, using documented procedures, to guide the users that operate and manage
it.
Query Processor
This transforms the user queries into a series of low level instructions. This reads the online
user’s query and translates it into an efficient series of operations in a form capable of being sent
to the run time data manager for execution.
Data Manager
Also called the cache manger, this is responsible for handling of data in the database, providing a
recovery to the system that allows it to recover the data after a failure.
Database Engine
The core service for storing, processing, and securing data, this provides controlled access and
rapid transaction processing to address the requirements of the most demanding data consuming
applications. It is often used to create relational databases for online transaction processing or
online analytical processing data.
Data Dictionary
This is a reserved space within a database used to store information about the database itself. A
data dictionary is a set of read-only table and views, containing the different information about
the data used in the enterprise to ensure that database representation of the data follow one
standard as defined in the dictionary.
Report Writer
Also referred to as the report generator, it is a program that extracts information from one or
more files and presents the information in a specified format. Most report writers allow the user
to select records that meet certain conditions and to display selected fields in rows and columns,
or also format the data into different charts.
DATABASE DESIGN
The database development life cycle has a number of stages that are followed when developing
database systems.
The steps in the development life cycle do not necessary have to be followed religiously in a
sequential manner.
On small database systems, the database system development life cycle is usually very simple
and does not involve a lot of steps.
In order to fully appreciate the above diagram, let's look at the individual components listed in
each step.
Requirements analysis
Planning - This stages concerns with planning of entire Database Development Life
Cycle It takes into consideration the Information Systems strategy of the organization.
System definition - This stage defines the scope and boundaries of the proposed database
system.
Database designing
Logical model - This stage is concerned with developing a database model based on
requirements. The entire design is on paper without any physical implementations or
specific DBMS considerations.
Physical model - This stage implements the logical model of the database taking into
account the DBMS and physical implementation factors.
Implementation
Data conversion and loading - this stage is concerned with importing and converting
data from the old system into the new database.
Testing - this stage is concerned with the identification of errors in the newly
implemented system .It checks the database against requirement specifications.
1. Normalization
2. ER Modeling
What is Normalization?
Normalization is a database design technique which organizes tables in a manner that reduces
redundancy and dependency of data.
It divides larger tables to smaller tables and links them using relationships.
The inventor of the relational model Edgar Codd proposed the theory of normalization with the
introduction of First Normal Form, and he continued to extend theory with Second and Third
Normal Form. Later he joined with Raymond F. Boyce to develop the theory of Boyce-Codd
Normal Form.
Theory of Data Normalization in SQL is still being developed further. For example, there are
discussions even on 6th Normal Form. However, in most practical applications, normalization
achieves its best in 3rd Normal Form. The evolution of Normalization theories is illustrated
below-
Database Normalization Examples -
Assume a video library maintains a database of movies rented out. Without any normalization,
all information is stored in one table as shown below.
Table 1
1NF Example
Table 1: In 1NF Form
What is a KEY?
A KEY is a value used to identify a record in a table uniquely. A KEY could be a single column
or combination of multiple columns
Note: Columns in a table that are NOT used to identify a record uniquely are called non-key
columns.
What is a Primary Key?
A composite key is a primary key composed of multiple columns used to identify a record
uniquely
In our database, we have two people with the same name Robert Phil, but they live in different
places.
Hence, we require both Full Name and Address to identify a record uniquely. That is a composite
key.
Let's move into second normal form 2NF
Rule 1- Be in 1NF
Rule 2- Single Column Primary Key
It is clear that we can't move forward to make our simple database in 2 nd Normalization form
unless we partition the table above.
Table 1
Table 2
We have divided our 1NF table into two tables viz. Table 1 and Table2. Table 1 contains
member information. Table 2 contains information on movies rented.
We have introduced a new column called Membership_id which is the primary key for table 1.
Records can be uniquely identified in Table 1 using membership id
Why do you need a foreign key?
A transitive functional dependency is when changing a non-key column, might cause any of the
other non-key columns to change
Consider the table 1. Changing the non-key column Full Name may change Salutation.
Rule 1- Be in 2NF
Rule 2- Has no transitive functional dependencies
To move our 2NF table into 3NF, we again need to again divide our table.
3NF Example
TABLE 1
Table 2
Table 3
We have again divided our tables and created a new table which stores Salutations.
There are no transitive functional dependencies, and hence our table is in 3NF
In Table 3 Salutation ID is primary key, and in Table 1 Salutation ID is foreign to primary key in
Table 3
Now our little example is at a level that cannot further be decomposed to attain higher forms of
normalization. In fact, it is already in higher normalization forms. Separate efforts for moving
into next levels of normalizing data are normally needed in complex databases. However, we
will be discussing next levels of normalizations in brief in the following.
Even when a database is in 3rd Normal Form, still there would be anomalies resulted if it has
more than one Candidate Key.
Sometimes is BCNF is also referred as 3.5 Normal Form.
If no database table instance contains two or more, independent and multivalued data describing
the relevant entity, then it is in 4th Normal Form.
A table is in 5th Normal Form only if it is in 4NF and it cannot be decomposed into any number
of smaller tables without loss of data.
6th Normal Form is not standardized, yet however, it is being discussed by database experts for
some time. Hopefully, we would have a clear & standardized definition for 6 th Normal Form in
the near future...
CREATION AND CONTROL
Introduction
The use of a computer database is typically involved in efficient data management. A shared,
integrated computer structure, a database stores the following:
In case you weren’t aware, metadata describes the characteristics of the data and the set of
relationships linking the data present within the database. So, what is the role of a DBMS in all
this? We discuss that next.
A DBMS plays a crucial role in both the creation and management of data. Without a database
management system, running and managing data effectively is not possible. Serving as the
intermediary between the user and the database, a DBMS provides users access to files stored in
a database. It provides the end user with a single, integrated view of the data, and translates all
applications it receives into complex operations that fulfil those requests. However, much of the
internal complexity of the database is hidden from the users and application programs.
From enabling the sharing of data in the database among multiple applications or users to
providing users with a single all-encompassing data repository, DBMS plays an important role in
information systems. Following are some of the things a DBMS enables in information systems:
With a DBMS, users within a company can access, update and delete data in a database or
information system. This information is easily available to users when the company’s
information systems are integrated with the relational DBMS.
A key function of database management systems is allowing different data sets to relate to one
another. This makes a DBMS ideal for managing relationships between data sets in a systematic
and simple way. This, in turn, allows managers to understand key statistics related to business
operations and sales.
The more people access the data, the greater the risk of data security breaches. Generally,
companies invest considerable time, effort and money to ensure proper use of their data. But, this
does not always produce the desired outcomes. With a DBMS, organizations can ensure better
enforcement of data privacy and security policies, which allows them to improve overall data
security
Concepts in database management hardly fall in the category of come-and-go, as the cost of
shifting between technical approaches overwhelms producers, managers, and designers.
However, there are several trends in database management, and knowing how to take advantage
of them will benefit your organization. Following are the some of the current trends:
The latest trends in database products are those that don’t simply
1. Databases that bridge SQL/NoSQL
embrace a single database structure. Instead, the databases bridge SQL and NoSQL, giving users
the best capabilities offered by both. This includes products that allow users to access a NoSQL
database in the same way as a relational database, for example.
3. Automated management
Automating database management is another emerging trend. The set of such techniques and
tools intend to simplify maintenance, patching, provisioning, updates and upgrades — even
project workflow. However, the trend may have limited usefulness since database management
frequently needs human intervention.