0% found this document useful (0 votes)
55 views40 pages

11 Unit 3

Uploaded by

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

11 Unit 3

Uploaded by

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

UNIT 3

DATABASE
MANAGEMEN
Data Management Approaches
Data management is an integral part
of our daily lives. Traditionally, data
used to be managed manually using
physical papers. As the size of data
that organizations manage become
larger and larger, computers have
become instrumental for efficient
management of data . The first
computer-based data
management is a file-based data
management approach.
The database approach was
introduced later and addressed
the inherent(natural)
weaknesses of the file-based
approach.
File based data management
File based data management is a
system of data management based
on a single file.
 File-based data management is an
approach in which data is stored in
separate files without
explicit(clean) relationships.
Data in different files is managed
by different application programs.
Any change to data requires
modification of the program that
uses the data. Changes made on
the program may also require
change in the file structure.
In file-based
datamanagement approach,
each department creates and
processes its own files
separately. For example,
procurement and finance
departments create and
manage their own files.
It creates problems of data
duplication and data
inconsistency. For example, let
us say employee data is stored
both in human resource and
finance departments. When
human resource department
modifies the employee records
upon hiring new employees.
it may not communicate the
information to the finance
department. As a result, different
information about employees
would be found in one
organization.
Such types of contradictions are
caused by the fact that data in one
file is not linked to data in other
files of the same organization in the
file-based approach. The isolation
of data also makes retrieval of data
of the entire organization a very
difficult task. These problems led
to the development of the database
approach.
A dtabase approach to data management

data is managed by a database using a


database management system (DBMS)
software. A database is a collection of
logically-related data.
It stores all organization’s data in one
repository.
A database is created to address the
data requirements of different user
groups and application programs in an
It is used to maintain internal
records of organizations such as
student records for schools,
customer records and daily sales
records for supermarkets, patient
database for hospitals.
Data in the database are used to
generate different information that
are used in the daily business
activities..
For example, the sales man in a
supermarket uses database to
generate daily or monthly sales
reports. Hospitals may generate
report that shows the most
frequent disease types in the last
year.
DBMS is software that manages
databases. DBMS is used to add
new data, modify data and delete
It is also used to retrieve data from
the database. DBMS essentially
serves as an interface between the
database and end users or
application programs. It ensures
that data is easily accessed by
potential users.
The database management process has three main components

the bottom is the database which stores the actual


data
In the middle is a DBMS which manages the database
At the top of the DBMS are application programs that
use the database.
The application programs
submit database query to the
DBMS. Then, the DBMS
retrieves data that matches the
queries and replies retrieved
data to the application programs.
Some
 Data advantages
independence: of DBMS is
A database
created to store all organization data
and support all users of the
organization. Each user or department
does not need to manage its own
isolated data.
 Data sharing: all organization’s data is
stored in one central database. DBMS
allows this central database to be
Avoiding data redundancy: Isolated
departmental files are stored in one
central database. The DBMS can
retrieve data from multiple tables so as
to meet the requirement of different
database users or application programs.
 Improved data security: Data in the
database is accessed only by authorized
users. Only users who are given data
access right can access and modify data
in the database.
Data Model
Data model is a blueprint of the
database. It is used as a guide to store
data in a database. It shows database
entities, attributes and the
relationships between the entities. It
also specifies what data to store in the
database
 For example, a school database stores
data about students and teachers.
Basic Concepts in Data Modeling
Entities are people, places, or things
about which you want to keep
information in a database.
 For example, banks may keep data
about customers and bank account
entities. Similarly, a library may have
entities like book, loan and borrower.
Entities are equivalent to tables when
implemented in the database
Attributes are properties of entities
that are used to describe the entities.
an entity that are used to differentiate
one entity from other entity.
For example, customer entity may
have customer id, name, sex and
address as its attributes. On the other
hand, book entity may have author
name, book title and publication year
as its attributes. The two entities have
different attributes because they are
different entities.
A relationship is an association between
entities. For example, customer has
account in a bank. The verb ‘has’
indicates the relationship between
customer and bank account entities.
 The relationship between entities can
take different forms
One-to-one relationship
An instance of an entity has only one
instance in the other entity with which it
is associated .
For example, a country and a
capital city. A country is associated
with one capital city, and a capital
city is associated with only one
country.
Instance of an entity refers to a
single occurrence of an entity. For
example, “Addis Ababa” is an
instance of the entity “City”.
One-to-many relation
 An instance in one entity is
associated with many instances
in the other related entity
For example, a department
called ‘Computer Science’ is
associated with multiple
students.
Many-to-many relationship
Instances on both sides of the
relationship are associated with
multiple instances of the other
entity
For example, an employee may
work in multiple projects. At the
same time, a project may have
multiple employees assigned to it
Entity Relationship Diagram
Entity Relationship Diagram (ERD) is a visual
representation tool for data models.
It has three main components are entity, attribute and
relationship.
Entities are represented as a rectangle and
relationships as a line to show the association between
entities.
Attributes are represented as
ellipses.
The names of entities and
attributes are placed inside the
rectangle and the ellipse
respectively.
The names of relationships, on the
other hand, are placed r.ight on top
of the line
Relational
Relational Data Model
data model is a type of
data model that represents data in
terms of two-dimensional tables
called relations.
A relation is nothing but a table
of rows and columns. Each row,
also called a record or tuple ,
contains a unique instance of data.
These rows in the relation
denote a real-world entity.
The columns in a relation,
also known as attributes or
fields, are used to describe the
properties of relations. their
attributes, and theiR
relationships.
Student Name Sex Grade Address
ID

ST001 EMAN ALI f 12 Kebel 05

ST002 Mohammed M 11 Kebel 04


ali

ST003 EDAN HAILU F 10 Kebel 03

ST004 Habetamu M 10 Kebel 04


mulugeta
The relational data model
provides conceptual tools to
represent a data model of a
relational database. A
relational data model captures
a collection of relations their
attributes, and their
relationships.
Key

Terms
Attributes are properties of entities
that are used to describe the entities.
 Data model is a blueprint of the
database. Database is a shared
collection of logically related data.
DBMS which stands for database
management system is a software
which is used to create and manage
databases
Entities are people, places, or things about which you
want to keep information in a database.
Entity Relationship Diagram (ERD) is a visual
representation tool for data models.
Field refers to a column of a table in the database
table. It is similar to an attribute in the logical data
model.
 File based data management is a system of data
management based on a single file
Foreign key is an attribute in a table
that matches the primary key of
another related table.
Microsoft Access is relational DBMS
software. It is used to manage
databases.
 Primary Key is a field which has a
unique value for each record in a table.
Record is a row in a database table. It
stores data about one real-world object
represented in a table.
Relational data model is a type of
data model that represents data
in terms of two-dimensional
tables called relations.
Relational database is a type of
database that contains a logically
related set of tables. Relationship
is an association between entities.
RQ Write True if the statmente is correct
and False if it is incorrect.
1. A database is a collection of related data.
2. A database approach improves data sharing.
3. ERD is a visual representation of data model.
 4. There is only one type of relationship between
entities in the ER model.
5. Attributes are used to
describe the characteristics of
an entity.
6. Relational database stores
data in one file.. 7. A Primary
key is an attribute that has
duplicate values for different
records in a table
8. Tables are used to store data
Choose the correct answer from the given
alternatives.
1. _____ is used to store a logically
related data.
A. file B. database C. data model D.
DBMS
 2. The element of ERD that represents
real-world things such as people,
places, or events about which we want
to store data is called:
A. attributes B. database C. relationship
3. The properties of entities that
are used to differentiate one entity
from the other entity is called:
A. attributes B. database C.
relationship D. entity
4. _____________ is considered as
a blueprint of a database.
A. attributes B. database C. data
model D. entities
5. In a relational data model, entities are represented
as:
A. attributes B. relations C. data models D. databases
6. ____ is a container of database objects in Microsoft
Access.
A. field B. database C. table D. form
7. A field which has a unique value for each record of a
table is called:
A. foreign key B. attribute C. data type D. primary key
8. One of the following is not a valid data type name
for a field ___.
A. text or string B. number C. entity D. date
9. A Query in Microsoft Access is used to:
A. store data for future use B. select records from the
underlying table that meet some search criteria C.
create a form to facilitate data entry D. None
10. In order to retrieve data from two or more tables
through query, we must establish a _____ between
tables
A. field B. primary key C. relationship D. criteria

You might also like