Professional Documents
Culture Documents
Hierarchy of Data: Database File
Hierarchy of Data: Database File
Hierarchy of Data: Database File
Database
File
Record
Field
Byte
Bit
File Organization - Hierarchy of
Data
• Bit
– Smallest amount of data a computer can
read
– Bits are read as the Binary digits 1 and
0
• Translated into ON or OFF - YES or NO
– Eight bits make one Byte.
File Organization - Hierarchy of
Data
• Byte
– Eight bits make up one Byte.
– A byte makes up a character
• Letters or Numbers like 1 or A
– Several characters make up a word
• Persons name, address, age.
File Organization - Hierarchy
of Data
• Field
– Words made up of characters
(bytes) produce what is known as a
field.
– Represents a piece of data
• Name, address, account number
File Organization - Hierarchy
of Data
• Record
– Collection of related fields
• Clients Contact Information
– Name, Address, Phone, E-mail,
Company
File Organization - Hierarchy
of Data
• File
– Collection of related records.
• A collection of records or documents
dealing with one organization, person,
area or subject.
– Manual (paper) files
– Computer files
Database
– A collection of related data with an
implicit meaning. A collection of similar
records with relationships between the
records.
– Properties of database
• Changes to real world related to database is
reflected in database .
• Is a logically coherent collection of data with some
inherent meaning .
• A database is built , designed and populated with
data for a specific purpose.
Traditional File Environment
Problems with Traditional File
systems
• Data redundancy – same piece of data
found in several places.
• Data inconsistency – various copies of
data no longer agree.
• Difficulty in accessing data
• Data Integrity – constraints to be
satisfied
• Data isolation – data in several application
data files is hard to access and integrate.
• Security – may be difficult to limit access to
various data items in applications.
Database : The Modern Approach
The database management system provides access to
the data
common in PC
environment because it is
simple to understand.
provides high flexibility Gives best processing
and ease of use. speeds, but poor query
provides slower search flexibility.
and access times; a
problem in high-volume
business settings.
Network Model
Gives pretty good processing speeds
and pretty good query flexibility, but
is very complex.
Some of the more popular relational
database management systems include:
– Microsoft Access
– Filemaker
– Microsoft SQL Server
– MySQL
– Oracle
DBMS Basics
Database Components:
A Database consists of
Table Characteristics
• each row is unique and stores data about one entity
• each column has a unique attribute name
• all entries in a column have the same data type
• each cell contains atomic data: no lists or sub-tables
• row and column order is unimportant .
Basic Concepts
• A primary key is an attribute or a collection of
attributes whose value(s) uniquely identify each row
in a relation. A table can only have one primary
key . Eg:
221 7883 1.20 -20.7 35.1 … 6625 123 100 7.6 165 …
225 7883 0.04 -17.5 34.9 … 7883 456 452 35.1 200 …
7884 456 255 35.2 190 …
278 7884 1.54 -19.4 35.2 …
9885 789 30 67.0 110 …
… … … … … …
… … … … … …
Galaxy
SubHalo
Types of relationships: