0% found this document useful (0 votes)
3 views37 pages

IIT Unit 9

The document provides an overview of fundamental concepts related to databases, including definitions of data, databases, and database management systems (DBMS). It discusses various database architectures, benefits of using databases over file-oriented approaches, and introduces data models, schemas, and instances. Additionally, it covers the roles of database administrators, database languages, and applications of databases in different organizational contexts.

Uploaded by

dulal.tony.mad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views37 pages

IIT Unit 9

The document provides an overview of fundamental concepts related to databases, including definitions of data, databases, and database management systems (DBMS). It discusses various database architectures, benefits of using databases over file-oriented approaches, and introduces data models, schemas, and instances. Additionally, it covers the roles of database administrators, database languages, and applications of databases in different organizational contexts.

Uploaded by

dulal.tony.mad
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 37

Fundamentals of Database

Unit 9

Compiled By: Dharmendra Thapa 1


In this Chapter

 Database
 Database System
 Database Management System
 Database System Architectures
 Database Applications
 Introduction to Data Warehousing, Data mining, and BigData

Compiled By: Dharmendra Thapa 2


What is Data?

Data is a collection of facts, such as numbers, words,


measurements, observations or just descriptions of things.

Compiled By: Dharmendra Thapa 3


Database

 Database is a repository or collection of logically related, and


similar data.
 Database stores similar kind of data.
 From the database; the information can be derived from it,
modified, data added, or deleted to it, and used when needed.
 Examples,
 Telephone directory
 Railway timetable
 Dictionary
 companies listed on Stock Exchange

Compiled By: Dharmendra Thapa 4


File-oriented approach

 A file is an object on a computer that stores data, information,


settings, or commands used with a computer program.
 In the early days, data was stored in files.
 For an application, multiple files are required to be created.
Each file stores and maintains its own related data.
 For example, a student information system would include files
like student profile, student course, student result, student fees
etc.
 The application is built on top of the file system.

Compiled By: Dharmendra Thapa 5


File-Oriented Approach vs. Database Approach
 There are many drawbacks of using the file system, as discussed below
 Data redundancy means storing the same data at multiple locations.
In an application, a file may have fields that are common to more than
one file.
 Data inconsistency means having different data values for the
common fields in different files.
 The files in which the data is stored can have different file formats.
This results in difficulty in accessing the data from the files since
different methods are required for accessing the data from the files
having different formats.
 In a file system, the constraints of the system (for example, student
age >17) become part of the program code. Adding new constraints or
changing an existing one becomes difficult.
 The files can be accessed concurrently by multiple users.
Uncontrolled concurrent access may lead to inconsistency and
security problems.
 Database approach provides solutions for handling the problems of the
file system approach. Compiled By: Dharmendra Thapa 6
Benefits of database approach
 The main characteristics(benefits) of the database approach are
defined as follows:
1. Data Redundancy is Minimized: Database system keeps data
at one place in the database.
2. Data Inconsistency is Reduced: Minimizing data redundancy
using database system reduces data inconsistency too.
3. Data is Shared: Data sharing means sharing the same data
among more than one user.
4. Data Independence: In the database approach, data
descriptions are stored in a central location called the data
dictionary. This property allows an organization’s data to
change and evolve (within limits) without changing the
application programs that process the data.

Compiled By: Dharmendra Thapa 7


Benefits of database approach
5. Data Integrity is Maintained: The integrity and consistency of
the database are protected using constraints on values that
data items can have.
6. Data Security is Improved: The data base is kept secure by
limiting access to the database by authorized personnel.
7. Backup and Recovery Support: Backup and recovery are
supported by the software that logs changes to the database.
8. Standards are Enforced: Since the data is stored centrally, it is
easy to enforce standards on the database.
9. Application Development Time is Reduced: The database
approach greatly reduces the cost and time for developing
new business applications.

Compiled By: Dharmendra Thapa 8


Data Models
 The information stored inside a database is represented using
data modeling.
 The data model describes the structure of the database.
 A data model consists of components for describing the data,
the relationships among them, and the semantics of data and
the constraints that hold data.
 Many data models exist based on the way they describe the
structure of database.
 The data models are generally divided into three categories as
follows:
1. High level or conceptual Data Model,
2. Representation or implementation Data Model, and
3. Low level or physical Data Model

Compiled By: Dharmendra Thapa 9


High-Level or Conceptual Data Model

 The conceptual data model is a description of the data


requirements of the user.
 This model is not concerned with the implementation details.
 It ensures that all the functional and data requirements of the
users are specified, conceptually.
 Example, Entity-Relationship model (E-R model)

Compiled By: Dharmendra Thapa 10


Entity-Relationship model (E-R model)
 ER model stands for an Entity-Relationship model.
 It is a high-level data model.
 This model is used to define the data elements and relationship
for a specified system.
 ER model consists of:
1. Entity: An entity may be any object, class, person or place. In
the ER diagram, an entity can be represented as rectangles.
2. Attribute: The attribute is used to describe the property of an
entity. Eclipse is used to represent an attribute.
3. Relationship: A relationship is used to describe the relation
between entities. Diamond or rhombus is used to represent the
relationship.

Compiled By: Dharmendra Thapa 11


Entity-Relationship model (E-R model)
Example

Figure: Sample ER-diagram

Compiled By: Dharmendra Thapa 12


Representation or Implementation Data Model
 The Conceptual Data Model is transformed into the
Representation Data Model.
 Representation data model uses concepts that are understood
by the end-user and are also close to the way the data is
organized in the computer.
 These models hide the details of data storage.
 The data models are broadly classified as traditional data
models that include:
1. Hierarchical
2. Relational, and
3. Network data models.

Note: Object-relational data model is an emerging data model.


Compiled By: Dharmendra Thapa 13
Relational Database Model

 This type of model designs the data in the form of rows and
columns within a table.
 Thus, a relational model uses tables for representing data and
in-between relationships.
 Tables are also called relations. This model was initially
described by Edgar F. Codd, in 1969.

Compiled By: Dharmendra Thapa 14


Hierarchical Database Model
 The Hierarchical Database Model was developed by IBM and
is the oldest database model.
 The schema of a hierarchical database is represented using a
tree-structure diagram.

15
Compiled By: Dharmendra Thapa
Network Database Model
 The Network Database Model was formalized by DataBase Task
Group (DBTG) group of Conference on Data Systems Languages
(CODASYL) in the late 1960s.
 The schema of the network database model is represented using a
data-structure diagram.
 The boxes represent the record type and the lines represent the links

16
Compiled By: Dharmendra Thapa
Low-Level or Physical Data Model
 The Physical Data Model describes the internal storage structures,
the access mechanism, and the organization of database files.
 Physical level describes how a record (e.g., customer) is stored.
 Sequential files, direct files, and indexed sequential files are
the different types of file organizations at the physical level.

Compiled By: Dharmendra Thapa 17


Schema and Instances
Schema:
 Schema is the logical structure of the database.
 A schema contains information about the descriptions of the
database like the names of the record type, the data items
within a record type, and constraints.
 A schema does not show the data in the database.
 The database schema does not change frequently.

Instances:
 Instances are the actual data contained in the database at a
particular point of time. The content of the database may
change from time to time.

Compiled By: Dharmendra Thapa 18


Database System

 A database system is a computerized record keeping system.


 The purpose of the database system is to maintain the data and
to make the information available on demand.
 A database system has four main components:
1. Users,
2. Hardware,
3. Software, and
4. Data.

Compiled By: Dharmendra Thapa 19


Database System
 Users:
 Users are the people who interact with the database system.
 The users of a database system are segregated into three
categories based on the way they interact with the system:
1. Application Programmers,
2. End Users, and
3. Data Administrators
 Software:
 In a database system, software lies between the stored data and the
users of data.
 The database software can be broadly classified into three types:
1. Database Management System (DBMS),
2. Application software, and
3. User Interface.
 Hardware: Hardware is the physical device on which the database
system resides.
 Data: Data is raw numbers, characters, or facts represented by values.
Compiled By: Dharmendra Thapa 20
Architecture of Database System
 The architecture of a database system provides a general
framework for database systems.
 The architecture for database system is proposed by
ANSI/SPARC study group and is called ANSI/SPARC
architecture.
 The ANSI/SPARC architecture is divided into three levels.
 Internal (Physical) Level has an internal schema. The internal
schema describes the physical storage structure of the database.
 Conceptual Level has a conceptual schema. The conceptual
schema describes the structure of whole database for the users.
 External Level or View Level provides a user’s and
application’s view of the data. It includes one or more external
schema.

Compiled By: Dharmendra Thapa 21


Architecture of Database System

Figure: Three schema architecture


Compiled By: Dharmendra Thapa 22
Data Independence
 Data independence is defined as the ability to change a schema
at one level without affecting the schema at another level.
 The mapping from the external level to conceptual level and
from the conceptual level to the physical level provides two
types of data independence:
 Logical Data Independence and
 Physical Data Independence.
1. Logical Data Independence. is the ability to modify the
conceptual schema without resulting in a change in the
external schema.
2. Physical Data Independence is the ability to modify the
physical schema without changing the conceptual schema.

Compiled By: Dharmendra Thapa 23


Database Management System (DBMS)

 DBMS is a software system for creating, organizing and


managing the database.
 DBMS handles all access to the database and manages the
database.
 Managing the database implies that it provides a convenient
environment to the user to perform operations on the database
for creation, insertion, deletion, updating, and retrieval of data.
 DBMS defines the scope of the use of database.
 Examples,
 MS-Access, MySQL, Oracle, DB2, SQL Server etc.

Compiled By: Dharmendra Thapa 24


Data Dictionary
 Data dictionary stores the data about the actual data stored in
the database.
 Data dictionary contains metadata, i.e. data about the data.
 Metadata is the data that describe the properties or
characteristics of other data.
 Data dictionary keeps track of the following:
1. Definitions of all data items in the database—It includes the
elementary-level data items (fields), group and record-level
data structures, and files or relational tables.
2. Relationships that exists between various data structures,
3. Indexes that are used to access data quickly, and
4. Screen and report format definitions that may be used by
various application programs.

Compiled By: Dharmendra Thapa 25


Database Administrator (DBA)
 DBA is a person or a group of persons who have centralized
control of the database.
 DBA coordinates all activities of the database system.
 The DBA is responsible for creating, modifying and
maintaining the three levels of DBMS architecture.
 The functions of DBA include:
1. defining of schema,
2. defining of storage structure and access method,
3. modification of schema and physical organization,
4. granting user authority to access the database, and
5. acting as liaison with users, monitoring performance, and
responding to changes in requirements.

Compiled By: Dharmendra Thapa 26


Database Languages
 A DBMS has appropriate languages and interfaces to express
database queries and updates.
 Database languages can be used to read, store and update the
data in the database.
 It is broadly divided into two types:
1. Data Definition Language (DDL), and
2. Data Manipulation Language (DML).
 DDL is used by database designers for defining the database
schema.
 DML is used for the manipulation of data.
 Structured Query Language (SQL) is a relational database
language that represents a combination of both DDL and
DML.

Compiled By: Dharmendra Thapa 27


Database System Architecture

 The architecture of databases of three kinds:


1. Centralized DBMS Architecture,
2. Client-Server Architecture, and
3. Distributed Databases.

Compiled By: Dharmendra Thapa 28


Centralized DBMS Architecture
 Centralized databases are the traditional database systems where all
database functionality, data, application program and user interface
processing are located on one machine.
 Access to the database from remote locations is via the
communication links

Compiled By: Dharmendra Thapa 29


Client-Server Architecture
 Client-Server systems involve a client machine and a server
machine.
 Clients are PCs or workstations that have user interface
capability and functionality for local processing.
 Servers are powerful computers that can manage the files (file
servers), printer (printer servers), or, e- mails (e-mail servers).
 The client is connected to the server via a communication link.
 The client interacts with the server when it requires access to
any additional functionality that does not exist in its own
machine.
 Client provides interfaces to access and utilize the server
resources.

Compiled By: Dharmendra Thapa 30


Types of Client-Server Architecture

 The functionality of client-server architecture is in various


tiers.
1. 1-tier Architecture
2. 2-tier Architecture
3. 3-tier Architecture
4. N-tier Architecture

Compiled By: Dharmendra Thapa 31


Distributed Databases
 A distributed database is one with decentralized functionality of the
DBMS.
 It is distributed among a number of computers.

32
Compiled By: Dharmendra Thapa
Database Applications

 The database applications can be for different purposes like:


1. Personal databases that support one user with a stand-alone
personal computer,
2. Workgroup databases for a small team of people (less than 25)
who work in collaboration on a project,
3. Departmental databases designed to support the various
functions and activities of a department (a functional unit of
an organization), and
4. Enterprise databases to support organization-wide operations
and decision making. Data warehouse is an enterprise
database.

Compiled By: Dharmendra Thapa 33


Data Warehousing

 Data warehousing is the process of constructing and using a


data warehouse.
 A data warehouse is constructed by integrating data from
multiple heterogeneous sources that support analytical
reporting, structured and/or ad hoc queries, and decision
making.
 Data warehousing involves data cleaning, data integration, and
data consolidations.

Compiled By: Dharmendra Thapa 34


Data Mining

 The process of extracting information to identify patterns,


trends, and useful data that would allow the business to take
the data-driven decision from huge sets of data is called Data
Mining.
 Data mining is the act of automatically searching for large
stores of information to find trends and patterns that go beyond
simple analysis procedures.
 Data mining utilizes complex mathematical algorithms for data
segments and evaluates the probability of future events.
 Data Mining is also called Knowledge Discovery of Data
(KDD).

Compiled By: Dharmendra Thapa 35


Big Data

 The definition of big data is data that contains greater variety,


arriving in increasing volumes and with more velocity.
 This is also known as the three Vs.
 Put simply, big data is larger, more complex data sets,
especially from new data sources.
 These data sets are so voluminous that traditional data
processing software just can’t manage them.
 But these massive volumes of data can be used to address
business problems you wouldn’t have been able to tackle
before.

Compiled By: Dharmendra Thapa 36


End Of Unit 9

Compiled By: Dharmendra Thapa 37

You might also like