09.02.
21
Database Management System
DBMS stands for Database Management System. We can break it like this
DBMS = Database + Management System. Database is a collection of data and
Management System is a set of programs to store and retrieve those data. Based on
this we can define DBMS like this: DBMS is a collection of inter-related data and
set of programs to store & access those data in an easy and effective manner.
Database Management System or DBMS in short refers to the technology of
storing and retrieving user’s data with utmost efficiency along with appropriate
security measures.
What is Data?
Data is a collection of a distinct small unit of information. It can be used in a
variety of forms like text, numbers, media, bytes, etc. it can be stored in pieces of
paper or electronic memory, etc.
Word 'Data' is originated from the word 'datum' that means 'single piece of
information.' It is plural of the word datum.
In computing, Data is information that can be translated into a form for efficient
movement and processing. Data is interchangeable.
What is a Database?
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.
The database is a collection of inter-related data which is used to retrieve, insert
and delete the data efficiently. It is also used to organize the data in the form of a
table, schema, views, and reports, etc.
For example: The college Database organizes the data about the admin, staff,
students and faculty etc.
Using the database, you can easily retrieve, insert, and delete the information.
10.02.21
What is DBMS?
Database Management System (DBMS) is 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.
o Database management system is software which is used to manage the
database. For example: MySQL, Oracle, etc are a very popular commercial
database which is used in different applications.
o DBMS provides an interface to perform various operations like database
creation, storing data in it, updating data, creating a table in the database and
a lot more.
o It provides protection and security to the database. In the case of multiple
users, it also maintains data consistency.
What is the need of DBMS?
Database systems are basically developed for large amount of data.
When dealing with huge amount of data, there are two things that
require optimization:
Storage of data
and
Retrieval of data
Storage: According to the principles of database systems, the data is stored in
such a way that it acquires lot less space as the redundant data (duplicate data) has
been removed before storage. Let’s take a layman example to understand this:
In a banking system, suppose a customer is having two accounts, one is saving
account and another is salary account. Let’s say bank stores saving account data at
one place and salary account data at another place, in that case if the customer
information such as customer name, address etc. are stored at both places then this
is just a wastage of storage (redundancy/ duplication of data), to organize the data
in a better way the information should be stored at one place and both the accounts
should be linked to that information somehow. The same thing we achieve in
DBMS.
Fast Retrieval of data: Along with storing the data in an optimized and
systematic manner, it is also important that we retrieve the data quickly when
needed. Database systems ensure that the data is retrieved as quickly as possible.
DBMS allows users the following tasks:
o Data Definition: It is used for creation, modification, and removal
of definition that defines the organization of data in the database.
o Data Updation: It is used for the insertion, modification, and
deletion of the actual data in the database.
o Data Retrieval: It is used to retrieve the data from the database
which can be used by applications for various purposes.
o User Administration: It is used for registering and monitoring
users maintain data integrity, enforcing data security, dealing with
concurrency control, monitoring performance and recovering
information corrupted by unexpected failure.
Characteristics of DBMS
o It uses a digital repository established on a server to store and manage the
information.
o It can provide a clear and logical view of the process that manipulates data.
o DBMS contains automatic backup and recovery procedures.
o It contains ACID properties which maintain data in a healthy state in case of
failure.
o It can reduce the complex relationship between data.
o It is used to support manipulation and processing of data.
o It is used to provide security of data.
o It can view the database from different viewpoints according to the
requirements of the user.
Advantages of DBMS
o Controls database redundancy: It can control data redundancy because it
stores all the data in one single database file and that recorded data is placed
in the database.
o Data sharing: In DBMS, the authorized users of an organization can share
the data among multiple users.
o Easily Maintenance: It can be easily maintainable due to the centralized
nature of the database system.
o Reduce time: It reduces development time and maintenance need.
o Backup: It provides backup and recovery subsystems which create
automatic backup of data from hardware and software failures and restores
the data if required.
o multiple user interface: It provides different types of user interfaces like
graphical user interfaces, application program interfaces
Disadvantages of DBMS
o Cost of Hardware and Software: It requires a high speed of data processor
and large memory size to run DBMS software.
o Size: It occupies a large space of disks and large memory to run them
efficiently.
o Complexity: Database system creates additional complexity and
requirements.
o Higher impact of failure: Failure is highly impacted the database because
in most of the organization, all the data stored in a single database and if the
database is damaged due to electric failure or database corruption then the
data may be lost forever.
Database Applications – DBMS
Applications where we use Database Management Systems are:
Telecom: There is a database to keeps track of the information
regarding calls made, network usage, customer details etc. Without
the database systems it is hard to maintain that huge amount of data
that keeps updating every millisecond.
Industry: Where it is a manufacturing unit, warehouse or
distribution centre, each one needs a database to keep the records of
ins and outs. For example distribution centre should keep a track of
the product units that supplied into the centre as well as the
products that got delivered out from the distribution centre on each
day; this is where DBMS comes into picture.
Banking System: For storing customer info, tracking day to day
credit and debit transactions, generating bank statements etc. All
this work has been done with the help of Database management
systems.
Sales: To store customer information, production information and
invoice details.
Airlines: To travel though airlines, we make early reservations, this
reservation information along with flight schedule is stored in
database.
Education sector: Database systems are frequently used in schools
and colleges to store and retrieve the data regarding student details,
staff details, course details, exam details, payroll data, attendance
details, fees details etc. There is a hell lot amount of inter-related
data that needs to be stored and retrieved in an efficient manner.
Online shopping: You must be aware of the online shopping
websites such as Amazon, Flipkart etc. These sites store the product
information, your addresses and preferences, credit details and
provide you the relevant list of products based on your query. All
this involves a Database management system.
Atomicity is an all-or-none proposition.
Consistency guarantees that a transaction never leaves your database in a
half-finished state.
Isolation keeps transactions separated from each other until they’re finished.
Durability guarantees that the database will keep track of pending changes
in such a way that the server can recover from an abnormal termination.
DBMS V/s File System
Drawbacks of File system
Data redundancy: Data redundancy refers to the duplication of
data, let’s say we are managing the data of a college where a
student is enrolled for two courses, the same student details in
such case will be stored twice, which will take more storage
than needed. Data redundancy often leads to higher storage
costs and poor access time.
Data inconsistency: Data redundancy leads to data
inconsistency, let’s take the same example that we have taken
above, a student is enrolled for two courses and we have student
address stored twice, now let’s say student requests to change
his address, if the address is changed at one place and not on all
the records then this can lead to data inconsistency.
Data Isolation: Because data are scattered in various files, and
files may be in different formats, writing new application
programs to retrieve the appropriate data is difficult.
Dependency on application programs: Changing files would
lead to change in application programs.
Atomicity issues: Atomicity of a transaction refers to “All or
nothing”, which means either all the operations in a transaction
executes or none.
For example: Let’s say Steve transfers 100$ to Negan’s
account. This transaction consists multiple operations such as
debit 100$ from Steve’s account, credit 100$ to Negan’s
account. Like any other device, a computer system can fail let’s
say it fails after first operation then in that case Steve’s account
would have been debited by 100$ but the amount was not
credited to Negan’s account, in such case the rollback of
operation should occur to maintain the atomicity of transaction.
It is difficult to achieve atomicity in file processing systems.
Data Security: Data should be secured from unauthorized
access, for example a student in a college should not be able to
see the payroll details of the teachers, such kind of security
constraints are difficult to apply in file processing systems.
Advantage of DBMS over file system
There are several advantages of Database management system over file
system. Few of them are as follows:
No redundant data: Redundancy removed by data normalization.
No data duplication saves storage and improves access time.
Data Consistency and Integrity: As we discussed earlier the root
cause of data inconsistency is data redundancy, since data
normalization takes care of the data redundancy, data inconsistency
also been taken care of as part of it
Data Security: It is easier to apply access constraints in database
systems so that only authorized user is able to access the data. Each
user has a different set of access thus data is secured from the issues
such as identity theft, data leaks and misuse of data.
Privacy: Limited access means privacy of data.
Easy access to data – Database systems manages data in such a
way so that the data is easily accessible with fast response times.
Easy recovery: Since a database system keeps the backup of data,
it is easier to do a full recovery of data in case of a failure.
Flexible: Database systems are more flexible than file processing
systems.