You are on page 1of 14

Unit -5

A Database Management System (DBMS) is a software system that is designed to manage


and organize data in a structured manner. It allows users to create, modify, and query a
database, as well as manage the security and access controls for that database.
Key Features of DBMS
 Data modeling: A DBMS provides tools for creating and modifying data models, which
define the structure and relationships of the data in a database.
 Data storage and retrieval: A DBMS is responsible for storing and retrieving data from
the database, and can provide various methods for searching and querying the data.
 Concurrency control: A DBMS provides mechanisms for controlling concurrent access
to the database, to ensure that multiple users can access the data without conflicting with
each other.
 Data integrity and security: A DBMS provides tools for enforcing data integrity and
security constraints, such as constraints on the values of data and access controls that
restrict who can access the data.

 Backup and recovery: A DBMS provides mechanisms for backing up and recovering the
data in the event of a system failure.

File System Approach

 File based systems were an early attempt to computerize the manual system. It is also called
a traditional based approach in which a decentralized approach was taken where each
department stored and controlled its own data with the help of a data processing specialist. The
main role of a data processing specialist was to create the necessary computer file structures,
and also manage the data within structures and design some application programs that create
reports based on file data.
Consider an example of a student's file system. The student file will contain information
regarding the student (i.e. roll no, student name, course etc.). Similarly, we have a subject file
that contains information about the subject and the result file which contains the information
regarding the result.
Some fields are duplicated in more than one file, which leads to data redundancy. So to
overcome this problem, we need to create a centralized system, i.e. DBMS approach.

DBMS:
A database approach is a well-organized collection of data that are related in a meaningful way
which can be accessed by different users but stored only once in a system. The various
operations performed by the DBMS system are: Insertion, deletion, selection, sorting etc.

In the above figure, duplication of data is reduced due to centralization of data.


A Data Model in Database Management System (DBMS) is the concept of tools that are
developed to summarize the description of the database. Data Models provide us with a
transparent picture of data which helps us in creating an actual database. It shows us from the
design of the data to its proper implementation of data.
Types of Relational Models
1. Conceptual Data Model
2. Representational Data Model
3. Physical Data Model
It is basically classified into 3 types:-
1. Conceptual Data Model
The conceptual data model describes the database at a very high level and is useful to
understand the needs or requirements of the database. It is this model, that is used in the
requirement-gathering process i.e. before the Database Designers start making a particular
database. One such popular model is the entity/relationship model (ER model). The E/R
model specializes in entities, relationships, and even attributes that are used by database
designers.
Entity-Relationship Model( ER Model): It is a high-level data model which is used to
define the data and the relationships between them. It is basically a conceptual design of any
database which is easy to design the view of data.
Components of ER Model:
1. Entity: An entity is referred to as a real-world object. It can be a name, place, object,
class, etc. These are represented by a rectangle in an ER Diagram.
2. Attributes: An attribute can be defined as the description of the entity. These are
represented by Eclipse in an ER Diagram. It can be Age, Roll Number, or Marks for a
Student.
3. Relationship: Relationships are used to define relations among different entities.
Diamonds and Rhombus are used to show Relationships.

2. Representational Data Model


This type of data model is used to represent only the logical part of the database and does not
represent the physical structure of the database. The representational data model allows us to
focus primarily, on the design part of the database. A popular representational model is
a Relational model. The relational Model consists of Relational Algebra and Relational
Calculus. In the Relational Model, we basically use tables to represent our data and the
relationships between them.
3. Physical Data Model
The physical Data Model is used to practically implement Relational Data Model. Ultimately,
all data in a database is stored physically on a secondary storage device such as discs and
tapes. This is stored in the form of files, records, and certain other data structures. It has all
the information on the format in which the files are present and the structure of the databases,
the presence of external data structures, and their relation to each other. Here, we basically
save tables in memory so they can be accessed efficiently. In order to come up with a good
physical model, we have to work on the relational model in a better way. Structured Query
Language (SQL) is used to practically implement Relational Algebra.
This Data Model describes HOW the system will be implemented using a specific DBMS
system. This model is typically created by DBA and developers. The purpose is actual
implementation of the database.

Some Other Data Models


1. Hierarchical Model
The hierarchical Model is one of the oldest models in the data model which was developed by
IBM, in the 1950s. In a hierarchical model, data are viewed as a collection of tables, or we
can say segments that form a hierarchical relation. In this, the data is organized into a tree-like
structure where each record consists of one parent record and many children. Even if the
segments are connected as a chain-like structure by logical associations, then the instant
structure can be a fan structure with multiple branches. We call the illogical associations as
directional associations.

2. Network Model
The Network Model was formalized by the Database Task group in the 1960s. This model is
the generalization of the hierarchical model. This model can consist of multiple parent
segments and these segments are grouped as levels but there exists a logical association
between the segments belonging to any level. Mostly, there exists a many-to-many logical
association between any of the two segments.

3. Object-Oriented Data Model


In the Object-Oriented Data Model, data and their relationships are contained in a single
structure which is referred to as an object in this data model. In this, real-world problems are
represented as objects with different attributes. All objects have multiple relationships
between them. Basically, it is a combination of Object Oriented programming and a
Relational Database Model.

4. Float Data Model


The float data model basically consists of a two-dimensional array of data models that do not
contain any duplicate elements in the array. This data model has one drawback it cannot store
a large amount of data that is the tables can not be of large size.

5. Context Data Model


The Context data model is simply a data model which consists of more than one data model.
For example, the Context data model consists of ER Model, Object-Oriented Data Model, etc.
This model allows users to do more than one thing which each individual data model can do.
6. Semi-Structured Data Model
Semi-Structured data models deal with the data in a flexible way. Some entities may have
extra attributes and some entities may have some missing attributes. Basically, you can
represent data here in a flexible way.

Advantages of Data Models


1. Data Models help us in representing data accurately.
2. It helps us in finding the missing data and also in minimizing Data Redundancy.
3. Data Model provides data security in a better way.
4. The data model should be detailed enough to be used for building the physical database.
5. The information in the data model can be used for defining the relationship between tables,
primary and foreign keys, and stored procedures.
Disadvantages of Data Models
1. In the case of a vast database, sometimes it becomes difficult to understand the data model.
2. You must have the proper knowledge of SQL to use physical models.
3. Even smaller change made in structure require modification in the entire application.
4. There is no set data manipulation language in DBMS.
5. To develop Data model one should know physical data stored characteristics.
A Database stores a lot of critical information to access data quickly and securely. Hence it
is important to select the correct architecture for efficient data management. DBMS
Architecture helps users to get their requests done while connecting to the database. We
choose database architecture depending on several factors like the size of the database,
number of users, and relationships between the users. There are two types of database
models that we generally use, logical model and physical model. Several types of
architecture are there in the database which we will deal with in the next section.
Types of DBMS Architecture
There are several types of DBMS Architecture that we use according to the usage
requirements. Types of DBMS Architecture are discussed here.
 1-Tier Architecture
 2-Tier Architecture
 3-Tier Architecture
1-Tier Architecture
In 1-Tier Architecture the database is directly available to the user, the user can directly sit on
the DBMS and use it that is, the client, server, and Database are all present on the same
machine.

DBMS 1-Tier Architecture

Advantages of 1-Tier Architecture:

Simple Architecture: 1-Tier Architecture is the most simple architecture to set up, as only a
single machine is required to maintain it.
 Cost-Effective: No additional hardware is required for implementing 1-Tier Architecture,
which makes it cost-effective.
 Easy to Implement: 1-Tier Architecture can be easily deployed, and hence it is mostly
used in small projects.
2-Tier Architecture
The 2-tier architecture is similar to a basic client-server model. The application at the client
end directly communicates with the database on the server side. APIs like ODBC and JDBC
are used for this interaction. The server side is responsible for providing query processing and
transaction management functionalities. On the client side, the user interfaces and application
programs are run. The application on the client side establishes a connection with the server
side to communicate with the DBMS.
An advantage of this type is that maintenance and understanding are easier, and compatible
with existing systems. However, this model gives poor performance when there are a large
number of users.

DBMS 2-Tier Architecture

Advantages of 2-Tier Architecture


 Easy to Access: 2-Tier Architecture makes easy access to the database, which makes fast
retrieval.
 Scalable: We can scale the database easily, by adding clients or upgrading hardware.
 Low Cost: 2-Tier Architecture is cheaper than 3-Tier Architecture and Multi-Tier
Architecture.
 Easy Deployment: 2-Tier Architecture is easier to deploy than 3-Tier Architecture.
 Simple: 2-Tier Architecture is easily understandable as well as simple because of only two
components.
3-Tier Architecture
In 3-Tier Architecture, there is another layer between the client and the server. The client does
not directly communicate with the server. Instead, it interacts with an application server
which further communicates with the database system and then the query processing and
transaction management takes place. This intermediate layer acts as a medium for the
exchange of partially processed data between the server and the client. This type of
architecture is used in the case of large web applications.
DBMS 3-Tier Architecture

Advantages of 3-Tier Architecture


 Enhanced scalability: Scalability is enhanced due to the distributed deployment of
application servers. Now, individual connections need not be made between the client and
server.
 Data Integrity: 3-Tier Architecture maintains Data Integrity. Since there is a middle layer
between the client and the server, data corruption can be avoided/removed.
 Security: 3-Tier Architecture Improves Security. This type of model prevents direct
interaction of the client with the server thereby reducing access to unauthorized data.
Disadvantages of 3-Tier Architecture
 More Complex: 3-Tier Architecture is more complex in comparison to 2-Tier
Architecture. Communication Points are also doubled in 3-Tier Architecture.
 Difficult to Interact: It becomes difficult for this sort of interaction to take place due to
the presence of middle layers.

Data Independence

A major objective for three-level architecture is to provide data independence, which means
that upper levels are unaffected by changes in lower levels.

There are two kinds of data independence:

Logical Data Independence

Logical data independence indicates that the conceptual schema can be changed without
affecting the existing external schemas. The change would be absorbed by the mapping
between the external and conceptual levels. Logical data independence also insulates
application programs from operations such as combining two records into one or splitting an
existing record into two or more records. This would require a. change in the
external/conceptual mapping to leave the external view unchanged.

Physical Data Independence

Physical data independence indicates that the physical storage structures or devices could be
changed without affecting conceptual schema. The change would be absorbed by the mapping
between the conceptual and internal levels.

The Logical data independence is difficult to achieve than physical data independence as it
requires the flexibility in the design of database and prograll1iller should foresee the future
requirements or modifications in the design.

Database Administrator: A database administrator (DBA) is a person or group in charge of


implementing DBMS in an organization. The DBA job requires a high degree of technical
expertise. DBA consists of a team of people rather than just one person.
The primary role of Database administrator is as follows −

 Database design
 Performance issues
 Database accessibility
 Capacity issues
 Data replication
 Table Maintenance

Responsibilities of DBA

The responsibilities of DBA are as follows −


 Makes the decision concerning the content of the database.
 Plans the storage structure and access strategy.
 Provides the support to the users.
 Defines the security and integrity checks.
 Interpreter backup and recovery strategies.
 Monitoring the performance and responding to the changes in the requirements.
Skills required for DBA
The skills required to be a successful DBA are as follows −
 Database designing.
 Knowledge of Structured Query Language (SQL).
 Know about distributed architecture.
 Knowledge on different operating servers.
 Idea on Relational Database Management System (RDBMS).
 Ready to face challenges and solve the problems quickly.

Data Dictionary

A metadata (also called the data dictionary) is the data about the data. It is the self-describing
nature of the database that provides program-data independence. It is also called as the System
Catalog. It holds the following information about each data element in the databases, it
normally includes:

– Name
– Type
– Range of values
– Source
– Access authorization
– Indicates which application programs use the data so that, when a change in a data structure is
contemplated, a list of the affected programs can be generated.
The data dictionary is used to control the database operation, data integrity, and accuracy.
Metadata is used by developers to develop the programs, queries, controls, and procedures to
manage and manipulate the data.
Active and Passive Data Dictionaries

The data dictionary may be either active or passive. An active data dictionary (also called
integrated data dictionary) is managed automatically by the database management software.
Consistent with the current structure and definition of the database. Most of the relational
database management systems contain active data dictionaries that can be derived from their
system catalog.

The passive data dictionary (also called non-integrated data dictionary) is the one used only for
documentation purposes. Data about fields, files, people and so on, in the data processing
environment, are. Entered the dictionary and cross-referenced.

DDL is short name of Data Definition Language, which deals with database schemas and
descriptions, of how the data should reside in the database.

CREATE – to create database and its objects like (table, index, views, stored procedure,
function, and triggers)
ALTER – alters the structure of the existing database
DROP – delete objects from the database
TRUNCATE – remove all records from a table, including all spaces allocated for the records
are removed COMMENT – add comments to the data dictionary
RENAME – rename an object
DML is short name of Data Manipulation Language which deals with data manipulation and
includes most common SQL statements such SELECT, INSERT, UPDATE, DELETE etc, and
it is used to store, modify, retrieve, delete and update data in the database.
SELECT – retrieve data from a database
INSERT – insert data into a table
UPDATE – updates existing data within a table
DELETE – Delete all records from a database table
MERGE – UPSERT operation (insert or update)

Cloud Computing: Cloud computing is a virtualization-based technology that allows us to


create, configure, and customize applications via an internet connection. The cloud technology
includes a development platform, hard disk, software application, and database.

The term cloud refers to a network or the internet. It is a technology that uses remote servers on
the internet to store, manage, and access data online rather than local drives. The data can be
anything such as files, images, documents, audio, video, and more.

There are the following operations that we can do using cloud computing:
o Developing new applications and services
o Storage, back up, and recovery of data
o Hosting blogs and websites
o Delivery of software on demand
o Analysis of data
o Streaming videos and audios

Types of Cloud
There are the following 5 types of cloud that you can deploy according to the organization's
needs-

o Public Cloud
o Private Cloud
o Hybrid Cloud
o Community Cloud
o Multi Cloud

Public cloud is open to all to store and access information via the Internet using the pay-per-
usage method.

In public cloud, computing resources are managed and operated by the Cloud Service Provider
(CSP). The CSP looks after the supporting infrastructure and ensures that the resources are
accessible to and scalable for the users.

Due to its open architecture, anyone with an internet connection may use the public cloud,
regardless of location or company size. Users can use the CSP's numerous services, store their
data, and run apps. By using a pay-per-usage strategy, customers can be assured that they will
only be charged for the resources they actually use, which is a smart financial choice.
Private cloud is also known as an internal cloud or corporate cloud. It is used by
organizations to build and manage their own data centers internally or by the third party. It can
be deployed using Opensource tools such as Openstack and Eucalyptus.

Hybrid Cloud is a combination of the public cloud and the private cloud. we can say:

Hybrid Cloud = Public Cloud + Private Cloud

Hybrid cloud is partially secure because the services which are running on the public cloud can
be accessed by anyone, while the services which are running on a private cloud can be accessed
only by the organization's users. In a hybrid cloud setup, organizations can leverage the benefits
of both public and private clouds to create a flexible and scalable computing environment. The
public cloud portion allows using cloud services provided by third-party providers, accessible
over the Internet.

Community cloud allows systems and services to be accessible by a group of several


organizations to share the information between the organization and a specific community. It is
owned, managed, and operated by one or more organizations in the community, a third party, or
a combination of them.

In a community cloud setup, the participating organizations, which can be from the same
industry, government sector, or any other community, collaborate to establish a shared cloud
infrastructure. This infrastructure allows them to access shared services, applications, and data
relevant to their community.

Multi-cloud is a strategy in cloud computing where companies utilize more than one cloud
service provider or platform to meet their computing needs. It involves distributing workloads,
applications, and statistics throughout numerous cloud environments consisting of public,
private, and hybrid clouds.

Adopting a multi-cloud approach allows businesses to have the ability to select and leverage the
most appropriate cloud services from different providers based on their specific necessities.
This allows them to harness each provider's distinctive capabilities and services, mitigating the
risk of relying solely on one vendor while benefiting from competitive pricing models. '
Cloud computing service & deployment models

According to National Institute of Standards and Technology (NIST), Cloud computing is a


model for enabling ubiquitous, convenient, on-demand network access to a shared pool of
configurable computing resources (e.g., networks, servers, storage, applications, and services)
that can be rapidly provisioned and released with minimal management effort or service
provider interaction. This cloud model is composed of five essential characteristics, three
service models, and four deployment models.

Software as a Service (SaaS). The apailit proided to the osuer is to use the proider’s appliatios
running on a cloud infrastructure. The applications are accessible from various client devices
through either a thin client interface, such as a web browser (e.g., web-based email), or a
program interface.

Platform as a Service (PaaS). The capability provided to the consumer is to deploy onto the
cloud infrastructure consumer-created or acquired applications created using programming
languages, libraries, services, and tools supported by the provider.

Infrastructure as a Service (IaaS). The capability provided to the consumer is to provision


processing, storage, networks, and other fundamental computing resources where the consumer
can deploy and run arbitrary software, which can include operating systems and applications.
The consumer does not manage or control the underlying cloud infrastructure but has control
over operating systems, storage, and deployed applications; and possibly limited control of
select networking components (e.g., host firewalls).

You might also like