0% found this document useful (0 votes)
2 views13 pages

POD Chapter 2 Notes

Chapter 2 discusses various database models including Hierarchical, Network, Object Oriented, and Relational models, highlighting their structures, advantages, and disadvantages. It also covers types of database systems such as Centralized, Client/Server, Parallel, and Distributed databases, detailing their functionalities and benefits. The Relational Model is emphasized as the most widely used, offering ease of use and flexibility in data management.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
Download as pdf or txt
0% found this document useful (0 votes)
2 views13 pages

POD Chapter 2 Notes

Chapter 2 discusses various database models including Hierarchical, Network, Object Oriented, and Relational models, highlighting their structures, advantages, and disadvantages. It also covers types of database systems such as Centralized, Client/Server, Parallel, and Distributed databases, detailing their functionalities and benefits. The Relational Model is emphasized as the most widely used, offering ease of use and flexibility in data management.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 13

Chapter 2: Data Models and Database Types (12 Marks)

Database Models-

- A Database model defines the logical design and structure of a database which describes
how data will be stored, accessed and updated in a database management system.
- It gives idea how your final system or software will look like after development is
completed.
- List of data models:
1. Hierarchical Model
2. Network Model
3. Object Oriented Database Model
4. Entity-relationship Model
5. Relational Model
- Among these models, Relational Model is the most widely used database model.

Hierarchical Database Model:


- This database model organises data into a tree-like-structure, with a single root, to
which all the other data is linked.
- The hierarchy starts from the Root data, and expands like a tree, adding child nodes
to the parent nodes.
- It uses top down approach to structure data.
- The top of the tree is the parent and the branches are children.
- Each child can only have one parent but a parent can have many children.
- The data is stored in the form of records and these records are connected to one
another.
- This model efficiently describes many real-world relationships like index of a book,
recipes etc.
- In hierarchical model, data is organised into tree-like structure with one one-to-many
relationship between two different types of data, for example, one department can
have many courses, many professors and of-course many students.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 1


Advantages:
1. Due to its hierarchical structure it is easy to understand.
2. The Model allows easy addition and deletion of new Information.
3. Data Access is fast on top of hierarchy.
4. It promotes data sharing.
5. Parent/child relationship promotes conceptual simplicity and data integrity.
6. Database security is provided and enforced by DBMS.
7. It is efficient with 1:M relationships.
Disadvantages:
1. Data access is slow when Information is search on Lower Entities.
2. Many to Many Relationship are not supported.
3. Changes in structure require changes in all application programs.
4. There is no data definition or data manipulation language in the DBMS.
Network Database Model:
− This is an extension of the Hierarchical model.
− A unique feature of the network model is its schema, which is viewed as a
graph where relationship types are arcs and object types are nodes.
− In this database model data is more related as more relationships are
established.
− Also, as the data is more related, hence accessing the data is also easier and
fast.
− This database model was used to map many-to-many data relationships.
− This was the most widely used database model, before Relational Model was
introduced.
− Example:

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 2


Advantages:
− As it has many-many relationship, network database model can be easily
accessed in any table record in the database.
− For more complex data, it is easy to use because of the multiple relationship
founded among its data.
− Easy to navigate and search the information because of its flexibility.

Disadvantage:

− Difficult for first time users.


− Difficulties with alterations of the database because when information entered
can alter the entire database

Object Oriented Database Model:


− This model defines a database as a collection of objects.
− Object oriented data model is based upon real world situations.
− These situations are represented as objects, with different attributes.
− All these object have multiple relationships between them.
− Elements of Object oriented data model
i) Objects: An object is an abstraction of a real-world entity..
ii) Attributes and Method: Every object has certain characteristics. These are
represented using Attributes. The behaviour of the objects is represented
using Methods.
iii) Class: Similar attributes and methods are grouped together using a class. An
object can be called as an instance of the class.
- The DBMS developed with the help of such model is called as OODBMS (Object
Oriented Database Management System).
- Object oriented database models can be used for complex applications such as
databases for scientific experiments, geographic information systems, engineering
design and manufacturing.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 3


Advantages:
- It supports inheritance. Due to this we can reuse attributes and functionalities. It
reduces the cost of maintaining data multiple items.
- Codes are re-used because of inheritance.
- As each class binds its attributes and its functionality, it helps in representing the
real world objects.
Disadvantages:
− It is not widely developed and complete to use it in the database systems. Hence it
is not accepted by the users.

Relational Database Model:


- The most popular data model in DBMS is the Relational Model.
- Relational data model was first proposed by E.F. Codd hence he is known as father
of Relational Model.
- Relational database was an attempt to simplify database structure by making use of
tables and columns.
- Tables are known as “relations”, columns are known as “Attributes” and rows (or
records) are known as “Tuples”.
- A relational database is a collection of 2-dimensional tables which consists of rows
and columns.

Concepts:

1. Domain:
- A domain is the set of permitted values for one or more attributes.
- It defines the potential values that an attribute may hold.
- For e.g. If the age of the student in class is between 15 and 20, then we can define a set
of values for the age attribute of student a sthe set of integers between 15 and 20.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 4


2. Attribute:
- An attribute is a named column of a relation.
- For e.g. Student table has stud_id, Stud_name, Marks as attributes.
3. Tuple:
- Tuple can also be called as record.
- Record can be defined as any row of a table.
- For e.g. data of one student in one row in student table is tuple.
4. Relation:
- A relation is a table with columns and rows.
- Tables are used to hold information about the objects to be represented in the database.

Advantages of Relational Database Model:


1. Ease of use: Information as tables consisting of rows and columns is much easier to
understand .

2. Flexibility: information from multiple tables can be retrieved easily at a time by joining
the tables.

3. Security: Security control and authorization can also be implemented more easily by
moving sensitive attributes in a given table into a separate relation with its own
authorization controls.

4. Data Independence: if any changes are made in database structure then there is no
need to make changes in the program. For e.g. We can modify the size or data type of a
field without making any change in application.

5. Data Manipulation Language: it is easy to respond to query by means of SQL


(Structured Query Language).

Disadvantages of Relational Database Model:


1. Hardware Overheads: this model needs more powerful computing hardware and data
storage devices to perform DBMS asssigned task.

Comparison between Hierarchical, Network, Relational Database Model:

Hierarchical Network Relational


Data is organized in the tree Data is organized in Graph Data is organized in the form
like structure like structure of Tables.
Represents “one to many” Represents “many to many” Represents both “one to
relationship relationship many” and “many to many”
relationship
Difficult to access data Easy to access data Easy to access data
Less flexible Flexible Flexible

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 5


Types of Database System:

Centralized Database System:


− Centralized database is located, stored, and maintained in a single location.
− This location is most often a central computer or database system, for example
a desktop or server CPU, or a mainframe computer.
− In most cases, a centralized database would be used by an organization (e.g. a
business company) or an institution (e.g. a university.)
− Users access a centralized database through a computer network which is able
to give them access to the central CPU, which in turn maintains to the database
itself.
− In this architecture, the database physically resides on only one site and other
sites can access it through the network.

Advantages of centralized database system:


− Easy to use by end-users due to its simplicilty provided by storing all the data at
one location.
− It provides better data security as all the data of any organization is stored at
one place.
− Data kept in the same location is easy to change, re-organized, mirrored, or
analyzed.
− Updates to any given set of data are immediately received by every end-user.
− More cost effective than other types of database systems as labor, power supply
and maintenance costs are all minimized.

Disadvantages of centralized database ssytem:


− These are highly dependent on network connectivity. If the network is slower
then the time reuire to access data from database also increases.
− As there is only one copy of data and it is maintained in a single location. This
decreases efficiency of the system.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 6


− If there is no fault-tolerant setup and hardware failure occurs, all the data within
the database will be lost.

Client/ Server Database System:


− Client server database consists of two logical components.One is “Client”
and the other one is “Server”.
− Clients are those who send the request to perform a specific task to the
server.
− Servers are normally receive the command sent by the clients, perform
the task and sends the appropriate result back to the client.
− The Client machine runs own copy of an operating system. It runs one or
more applications through client’s CPU and memory.
− Server runs a database management system which manages the whole
database.

Advantages of Client server Database System:


− Centralized Database: the database is centrally available for all the clients
easily which is easy to manage.
− Proper Management : All the files are stored at the same place. In this
way, management of files becomes easy.
− Back-up and Recovery possible : As all the data is stored on server it is
easy to take the back-up. Also, in case of some break-down if data is lost,
it can be recovered easily and efficiently.
− Upgradation and Scalability in Client-server set-up : Changes can be
made easily by just upgrading the server. Also new resources and
systems can be added by making necessary changes in server.
− Accessibility : From various platforms in the network, server can be
accessed remotely.
− Security : Rules defining security and access rights can be defined at the
time of set-up of server.
− Server Role: Servers can play different roles for different clients.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 7


Disadvantages of Client server Database System:
− Congestion in Network :Too many requests from the clients may lead to
congestion. Overload can lead to breaking-down of servers.
− Cost : It is very expensive to install and manage this type of computing.
− There is need of professional IT people to maintain the servers and other
technical details of network.

Types of client server architecture:


- Normally, there are three types of client server architecture available in database
management system.
(a) Single tier client server computing model
(b) Two tier client server computing model
(c) Three tier client server computing model

(a) Single tier client server architecture:


− Single tier architecture is the first type of client server computing model.
− In single tier client server computing model, the client server database system is
used on a personal computer.
− In single tier system, the database is centralized, which means the DBMS
software and the data in one location and the dumb terminals were used to
access the database management system.

(b) Two Tier Client Server Architecture:


− It uses two computers and one client/server system.
− At the early stages, client server computing was called as two-tier computing
model in which client is considered as data capture and validation tier and
server was considered as data storage tier.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 8


c) Three Tier Architecture:
− Three tier architecture is the improvement over two tier architecture.
− Three tier architecture has three layers.
− The first layer is the user interface which runs on client system.
− The second layer is called the application server. It is used for business logic
and data processing.
− The third layer is known as database server. It is a database management
system which stores the data as needed by the middle layer.

Parallel Database System:


− Companies need to handle huge amount of data with high data transfer rate.
The client server and centralized system is not much efficient. For improving the
efficiency of the system, the concept of Parallel Databases comes in picture.
− Parallel database system improves performance of data processing using
multiple resources in parallel, like multiple CPU and disks are used parallely.
− A parallel database improves the speed of processing.
− A parallel server can allow access to a single database by users on multiple
machines, with increased performance.
− It also performs many parallelization operations like, data loading and query
processing.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 9


Advantages of parallel database system:
− Improve performance: The performance of the system can be improved by
connecting multiple CPU and disks in parallel. Many small processors can also
be connected in parallel.
− Improve availability of data: Data can be copied to multiple locations to improve
the availability of data. For example: if a module contains a table from database
which is unavailable then it is important to make it available from another
module.
− Improve reliability: Reliability of system is improved with completeness, accuracy
and availability of data.
− Provide distributed access of data: Companies having many branches in
multiple cities can access data with the help of parallel database system.

Disadvantages of parallel database system:


− Power consumption is huge by the multi core architectures.
− Better cooling technologies are required in case of clusters.

Distributed Database System:

− It is the type of database in which no. of databases are stored at various locations
and interconnected through the computer network.
− In other words, A distributed database is a collection of multiple interconnected
databases, which are spread physically across various locations that communicate
via a computer network.
− In distributed database system each site may have its own memory and its own
database server.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 10


Advantages of Distributed Database System:
− Modular development – Growth is easier. We do not need to interrupt any of the
functioning sites to add a new site. Hence, the expansion of the whole system is
easier. Removal of site is also does not cause much problems.
− More reliable- the possibility of the system running at any point is reliability. In
distributed databases, if one component fails to work, other component can take
over its function and due to this whole system does not affected.
− Improved performance- here, large database is distributed among multiple
sites. Due to this distribution a small database exists at each site and the small
database is easy to handle which ultimately improves performance.
− Improves availability- Data is scatteres at various sites. So if one node fails then
data can be easily available from another node.
− Faster response – Most of the data are local. Hence, the requests can be
answered quickly compared to a centralized system.
− Local control – The data is distributed in such a way that every portion of it is
local to some sites (servers). The site in which the portion of data is stored is the
owner of the data.
− Lower Communication Cost − In distributed database systems, if data is located
locally where it is mostly used, then the communication costs for data
manipulation can be minimized.

Disadvantages of Distributed Database System:


− Need for complex and expensive software − It demands complex and
expensive software to provide data transparency and co-ordination across the
several sites.
− Data integrity − The need for updating data in multiple sites pose problems of
data integrity.
− Security- it has access from all the sites therefore security becomes an assue
for distributed database system.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 11


For example:

Types of Distributed Database System:


There are two different types of distributed database:
i) Homogeneous Distributed Database System
ii) Heterogeneous Distributed Database System

i) Homogeneous Distributed Database System:


- In a homogeneous distributed database, all the sites use identical DBMS and operating
systems.
- Its properties are −
a) The sites use very similar software.
b) The sites use identical DBMS or DBMS from the same vendor.
c) Each site is aware of all other sites and cooperates with other sites to process user
requests.
d) The database is accessed through a single interface as if it is a single database.

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 12


ii) Heterogeneous Distributed Database System
- In a heterogeneous distributed database, different sites have different operating systems,
DBMS products and data models.
- Its properties are −
a) Different sites use dissimilar schemas and software.
b) The system may be composed of a variety of DBMSs like relational, network,
hierarchical or object oriented.
c) Query processing is complex due to dissimilar schemas.
d) Transaction processing is complex due to dissimilar software.
e) A site may not be aware of other sites and so there is limited co-operation in processing
user requests.

Difference between Centralized Database and Distributed Database:

Centralized Database Distributed Database


In Centralized DBMS the database are In Distributed DBMS the database are
stored in a only one site stored in different site and help of
network it can access it
Data is stored at a single computer Database and DBMS software
site,which can be used by multiple users distributed over many sites,connected
by a computer network
Database is maintained at one site Database is maintained at a number of
different sites
If centralized system fails,entire system If one system fails,system continues
is halted work with other site
It is less reliable It is more reliable

Prepared by: Mrs. M. P. Nawarkar [IF Dept] 13

You might also like