28
Database System Lecturer: Mr. Prum Chan Samedy, MScIT Tel: 012 456-896 E-mail: [email protected] Bachelor of Science in Information Technology

Chapter01 introduction

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Chapter01 introduction

Database System

Lecturer: Mr. Prum Chan Samedy, MScITTel: 012 456-896E-mail: [email protected]

Bachelor of Science in Information Technology

Page 2: Chapter01 introduction

Database system 2

Objectives

After finished this course students able to design to manage large bodies of information. Management of data involves both designing structure for storage of information and providing mechanisms for the manipulation of information.

Data Management– Build an Entity-Relationship model for a relational DBMS– Implement the database in MS Access/SQL Server– Normalize tables– Produce SQL coding to manage data

Application Development– Plan and design an application system– Implement an application in MS Access

Page 3: Chapter01 introduction

Database system 3

Fundamental of

Database systems, Elmasri & Navatthe

Class References

Page 4: Chapter01 introduction

Database system 4

Chapter 1:

Introduction Databases and

Database users

Database System

Page 5: Chapter01 introduction

Database system 5

Outline

Basic Definitions Typical DBMS Functionality Example of a Database (UNIVERSITY) Advantages of Using the Database Approach Database Users

Page 6: Chapter01 introduction

Database system 6

Basic Definitions- Data VS Information

DATA: Facts concerning people, objects, vents or other entities. Databases store data.INFORMATION: Data presented in a form suitable for interpretation. Data is converted into information by programs and queries.

Figure 1.1 Input-process-output

Page 7: Chapter01 introduction

Database system 7

Example of Data

Page 8: Chapter01 introduction

Database system

Why every employees in company need information?

Shopping in supermarket

Page 9: Chapter01 introduction

Database system 9

Basic Definitions – Database VS DBMS

DATABASE:

DATABASE MANAGEMENT SYSTEM (DBMS) :

A software system that enables users to define, create, and maintain the database and that provides controlled access to this database.

Page 10: Chapter01 introduction

Database system

Basic Definitions – Database System

DATABASE SYSTEM:

Database System =DBMS+Database

The DBMS software together with the data itself. Sometimes, the applications are also included.

Oracle, SQL Server,DB2, MySQL, Infomix,…

Page 11: Chapter01 introduction

Database system 11

Basic Definitions – Metadata

Metadata

“Data about data” Description of fields Display and format instructions

Structure of files and tables Security and access rules Triggers and operational rules

Example of Metadata

Page 12: Chapter01 introduction

Database system 12

Basic Definitions –Sample of Metadata

Sample of Metadata

Page 13: Chapter01 introduction

Database system 13

Simplified database system environment

A simplified database system environment

Page 14: Chapter01 introduction

Database system

Database application program

A software program that interacts with the database by issuing an appropriate request (typically an SQL statement) to the DBMS.

Page 15: Chapter01 introduction

Database system

Database Overview- Why Use a DBMS?

Using a DBMS to manage data has many advantages:

– Data independence – Sharing of data among multiple applications – Data integrity and security – Concurrent access and crash recovery– Data administration – Reduced application development time

Page 16: Chapter01 introduction

Database system 16

Database Users-1

Users may be divided into– Those who actually use and control the database

content, and those who design, develop and maintain database applications (called “Actors on the Scene”), and

– Those who design and develop the DBMS software and related tools, and the computer systems operators (called “Workers Behind the Scene”).

Page 17: Chapter01 introduction

Database system 17

Database Users-2

Actors on the scene– Database administrators:

Responsible for authorizing access to the database, for coordinating and monitoring its use, acquiring software and hardware resources, controlling its use and monitoring efficiency of operations.

– Database Designers/Ananyst: Responsible to define the content, the structure, the

constraints, and functions or transactions against the database. They must communicate with the end-users and understand their needs.

Page 18: Chapter01 introduction

Database system 18

Database Users-3

Application programmer/Application DeveloperThey access the data from programs written in high-level language such as Visual basic or C++,C#, Java. The application programmers design systems such as payroll, Inventory, and billing.

End userThey use the data for queries, reports and some of them update the database content.

Page 19: Chapter01 introduction

Database system 19

Exercise 1.1

Indicate which type of user would perform the following functions for a payroll system in a large company:

A. Write an application program to generate and print the checks.

B. Change the address in the database for an employee who has moved.

C. Create a new user account for a newly hired payroll clerk

Page 20: Chapter01 introduction

Database system 20

RDBMS

Relational Database Management System (RDBMS) – Relational Database is a collection of relations

(table) Oracle, SQL Server, DB2, My SQL,…

User tables Data dictionary

Page 21: Chapter01 introduction

Database system 21

Index

199011913 19959999

19860001 19901913 19911123 19959999

Indexcolumn

4327 2271 . . .

200000190000...

Prum Chan DaraKeo Rithy...

00427699...

19871992 . . .

5648180000Pich Oudam19131990

Dept_NoSalaryEmp_NameSerial_ No

Hire_Year

Row

Field

[EMPLOYEE table]

[DEPARTMENT table]

Dept_No Department Area

5648432722710381...

SystemsPersonnelGeneral affairsSales...

P.PKDKPKK...

Sample of Relational Database

Page 22: Chapter01 introduction

Database system 22

Database Architecture

Single tier Architecture Two-tier Architecture Three-tier Architecture

Page 23: Chapter01 introduction

Database system 23

DBMSSoftware

Database

a. Single tier:All on one machine Access by terminals

Single tier

Page 24: Chapter01 introduction

Database system 24

Client/Server (Two tier )

DBMS manages data resources like an operating system manages hardware resources

DBMSServer

Software

DBMSServer

Software

Databasecontainingcentralized

shared data

Application#1

Application#2

Application#3

Front-End/Client

b. Two-Tier:Server with many clients

Page 25: Chapter01 introduction

Database system 25

Three-tier architecture

c. Three-tier:Two kings of DBMS

Connected by Middleware

DBMS IServer

Software

Database

Middleware

Application#1

Application#2

DBMS IIServer

Software

Database

Application#3

Applicatio4#3

Front-End/ClientFront-End/Client

Page 26: Chapter01 introduction

Database system

Also call Distributed SystemsSolutions are distributed between client PC’s and one or more servers.

Three-tier architecture

Page 27: Chapter01 introduction

Database system 27

Exercise 1.2

Specify whether each system would be single-tiered, two-tiered, or three-tiered.

a. The Happy Nights motel chain allows local managers to purchase a franchise. They can install and use the DBMS of their choice for their reservation system. The only requirement is that they be able to connect and communicate with the central office’s system.

b. The Sticky Wicket Company has home offices in Detroit and branches in Chicago and Baltimore. The inventory and parts database is distributed with each branch keeping its own inventory. One central DBMS located in Detroit allows instant ordering of supplies through the central office.

Page 28: Chapter01 introduction

Database system 28