file systems and database systems

29

Upload: arvid

Post on 30-Jan-2016

52 views

Category:

Documents


0 download

DESCRIPTION

File Systems and Database Systems. Outline. Roots of the Database System: File System Problems with File System Data Management Database System. 1. File System. Case of a File. A manager of any small organization was able to keep track of necessary data using a manual file system. - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: File Systems and Database Systems
Page 2: File Systems and Database Systems

Outline

Roots of the Database System: File System

Problems with File System Data Management

Database System

Page 3: File Systems and Database Systems

File

System1

Page 4: File Systems and Database Systems

Case of a File A manager of any small

organization was able to keep track of necessary data using a manual file system.

A MANUAL FILE SYSTEM consist mainly of a collection of file folders, properly tagged(or labeled) and kept in a filing cabinet.

Page 5: File Systems and Database Systems

Manager’s File Cabinet

Technical:Data pertaining

to only those people whose

duties were properly

classified as TECHNICAL.

Page 6: File Systems and Database Systems

Doing well for a while

At first, data collection was relatively small and an organization’s manager had few reporting requirements, the manual system served its role well as a data storehouse.

Page 7: File Systems and Database Systems

But the organization grew… However, as the organization

grew and the storing requirements became more complex, keeping track of the data became more difficulty.

Retrieval was time consuming and cumbersome, thus, it is unlikely that the data could generate useful information.

Page 8: File Systems and Database Systems

Consider these questions: How many products sold during

the past week, month, quarter or year?

What is the current daily, weekly, quarterly or yearly sales peso volume?

Did we gain more this month compared to last month’s sales?

Page 9: File Systems and Database Systems

The Data Processing Specialist Thus, the manager needs to hire a

new kind of professional: a Data Processing (DP) Specialist.

The task is to be able to manage and process data. Process means to draw out useful information from the data.

The DP creates file structures, the software and design reports from the data.

Page 10: File Systems and Database Systems

Customers

Alfred Ramos

Phone: 0927-565-4896Address: #42 Rodeo St. Macabalan, CDOZIP: 9000

Agent Name: Leah VidalPhone: 0927-565-4444Insurance Type: T1Amount: P500.00Renewal Date: December 12, 2012

Page 11: File Systems and Database Systems

Customer FileC_NAME C_PHNE C_ADD C_ZIP A_NAME A_PHONE TP AMT REN

Alfred Ramos

0927-595-784 CDO 9000 Leah Vidal 0927-565-4444

T1 500.00 Dec 12, 2012

Jordan Belen

0928-594-5979 CDO 9000 Jasmin Trio 0927-332-1322

T1 100.00 Dec 15, 2012

RebeccaDuran

0917-449-459 DVO 8000 Leah Vidal 0927-565-4444

A1 250.00 Mar 2, 2012

Jose Reyes

0922-465-4465 DVO 8000 Jasmin Trio 00927-332-1322

T2 210.00 Mar 5, 2012

Dorothy Villafria

0927-466-7999 ILOILO 6800 Richard Silva 0922-526-4466

A2 100.00 Jan 3, 2013

Marco Mercedes

0922-965-1221 CBU 6000 Leah Vidal 0927-565-4444

T2 150.00 Jun 7, 2013

Kurt Cobaltito

0927-465-4652 ILOILO 6800 Leah Vidal 0927-565-4444

A1 200.00 Mar 29, 2012

Sophia Mendez

0927-465-4465 CEBU 6000 Richard Silva 0922-526-4466

A1 200.00 Apr 8,2013

Dominic Fuetlaki

0928-446-4656 ILIGAN 9200 Leah Vidal 0927-565-4444

T2 100.00 May 4, 2012

Page 12: File Systems and Database Systems

Consider these questions: How many agents do we

have? Sales per agent?

Page 13: File Systems and Database Systems

Singular File System

Each department has their own file system.

It is not the concern of the Customer’s Department.

The Customer’s Department must create their own file system.

Page 14: File Systems and Database Systems

CUSTOMER FILECUSTOMER FILE SALES FILESALES FILE

File Mgmt

Program

File Mgmt

Program

File Report

Program

File Report

Program

File Mgmt

Program

File Mgmt

Program

AGENT FILEAGENT FILE

File Report

Program

File Report

Program

Page 15: File Systems and Database Systems

FILESTRUCTUREFILESTRUCTURE

FILE SYSTEM PROGRAM

FILE SYSTEM PROGRAM

Page 16: File Systems and Database Systems
Page 17: File Systems and Database Systems

Problems with File System Data Management2

Page 18: File Systems and Database Systems

Task of a Filing System

Storing DataSaving and Organizing

Updating Data (Edit or Delete)

Retrieving DataProcessing Data to Reports

Page 19: File Systems and Database Systems

File Systems are inefficient with the three task

Page 20: File Systems and Database Systems

1. Data Retrieval Task 3GL Languages vs 4GL Languages 3 GL :

BASIC,C++, Fortran,CobolProgrammer to specify what must be done and how it

is to be done

4 GL :SQLProgrammers to specify what must be done without

specifying how it must be done.Save an average of 60% of lines of code

Page 21: File Systems and Database Systems

3GL vs 4GL3GL 4GL

DO WHILE NOT (EOF)Read CUSTOMERIF CUSTOMER.C_ZIP = “36123”

THEN PRINT C_NAME, C_PHONE, C_ZIP

ENDDO;

SELECT C_NAME,C_PHONE,C_ZIPFROM CUSTOMERWHERE CUSTOMER.C_ZIP=‘36123’;

1. It requires extensive programming2. There is no ad hoc query capabilities3. System Administration can be complex and difficulty4. It is difficult to make changes to existing structure5. Security features are likely to be inadequate

Page 22: File Systems and Database Systems

2. Data Storing and Organizing STRUCTURAL Structural Dependence: If the file

structure changes, the file system program must adapt.

Structural Independence: the file system program need not to change if the file structure changes

Page 23: File Systems and Database Systems

DATA Data Dependence: Data access

programs are subject to change when any of the file’s data storage characteristics change.

Data Independence: possible to make changes in the data storage characteristics without affecting the application program’s ability to access data.

Page 24: File Systems and Database Systems

2. Data Updating

Data RedundancyPremise: data should be accurate (no data

inconsistencies) and verifiable (always yield consistent results)

Data anomalies – develops when all of the required changes in the redundant data are not made successfulUpdate Anomalies – not all are updatedInsertion Anomalies Deletion anomalies -

Page 25: File Systems and Database Systems
Page 26: File Systems and Database Systems

Database Systems3

Page 27: File Systems and Database Systems

What is a DATABASE?

The database is consist of logically related data stored in a single logical data storeroom or repository.

Page 28: File Systems and Database Systems

Employees File System

Customers

SalesInventory

Accounting Department

Page 29: File Systems and Database Systems

Hardware Software People Procedures Structures