1 csbp430 – database systems chapter 1: databases and database users mamoun awad college of...

23
1 CSBP430 – Database Systems CSBP430 – Database Systems Chapter 1: Chapter 1: Databases and Database Databases and Database Users Users Mamoun Awad College of Information Technology United Arab Emirates University [email protected]

Upload: virgil-foster

Post on 28-Dec-2015

229 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

1

CSBP430 – Database SystemsCSBP430 – Database Systems

Chapter 1: Chapter 1: Databases and Databases and Database UsersDatabase Users

Mamoun AwadCollege of Information TechnologyUnited Arab Emirates [email protected]

Page 2: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

2

In this chapter, you will learn:

Basic Definitions

Example of a Database

Main Characteristics of Database Technology

Additional Benefits of Database Technology

When Not to Use a DBMS

Page 3: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

3

Basic Definitions

Database: A collection of related data.

Data: Known facts that can be recorded and have an implicit meaning.

Mini-world: Some part of the real world about which data is stored in a database. For example, student grades and transcripts at a university.

Database Management System (DBMS): A software package/system to facilitate the creation and maintenance of a computerized database.

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

Page 4: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

4

File Terminology

Data: Raw Facts

Field: Group of characters with specific meaning

Record: Logically connected fields that describe a person, place, or thing

File: Collection of related records

Page 5: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

5

Simple File System

Page 6: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

6

File System Critique

File System Data ManagementRequires extensive programming in third-generation language (3GL)Time consumingMakes ad hoc queries impossibleLeads to islands of information

Page 7: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

7

File System Critique (con’t.)

Data DependenceChange in file’s data characteristics requires modification of data access programsMust tell program what to do and howMakes file systems cumbersome from programming and data management views

Structural DependenceChange in file structure requires modification of related programs

Page 8: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

8

File System Critique (con’t.)

Data RedundancyDifferent and conflicting versions of same dataResults of uncontrolled data redundancy• Data anomalies

– Modification– Insertion– Deletion

• Data inconsistency– Lack of data integrity

Page 9: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

9

Database Systems

Database consists of logically related data stored in a single repository

Provides advantages over file system management approach

Eliminates inconsistency, data anomalies, data dependency, and structural dependency problemsStores data structures, relationships, and access paths

Page 10: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

10

Database vs. File Systems

Page 11: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

11

Database System Environment

Page 12: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

12

Example of a Database(with a Conceptual Data Model)

Mini-world for the example: Part of a UNIVERSITY environment.

Some mini-world entities:

- STUDENTs- COURSEs- SECTIONs (of COURSEs)- (academic) DEPARTMENTs- INSTRUCTORs

Some mini-world relationships:- SECTIONs are of specific COURSEs

- STUDENTs take SECTIONs- COURSEs have prerequisite COURSEs- INSTRUCTORs teach SECTIONs- COURSEs are offered by DEPARTMENTs- STUDENTs major in DEPARTMENTs

Page 13: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

13

Page 14: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

14

Page 15: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

15

Main Characteristics of Database Technology

Self-contained nature of a database system: A DBMS catalog stores the description of the database. The description is called meta-data). This allows the DBMS software to work with different databases.

Insulation between programs and data:

Called program-data independence. Allows changing data storage structures and operations without having to change the DBMS access programs.

Data Abstraction:

A data model is used to hide storage details and present the users with a conceptual view of the database.

Support of multiple views of the data:

Each user may see a different view of the database, which describes only the data of interest to that user.

Page 16: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

16

Page 17: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

17

Additional Benefits of Database Technology

Controlling redundancy in data storage and in development and maintenance efforts.

Sharing of data among multiple users.

Restricting unauthorized access to data.

Providing multiple interfaces to different classes of users.

Representing complex relationships among data.

Enforcing integrity constraints on the database.

Providing backup and recovery services.

Potential for enforcing standards.

Flexibility to change data structures.

Reduced application development time.

Availability of up-to-date information.

Economies of scale.

Page 18: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

18

Page 19: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

19

Importance of DBMS

Makes data management more efficient and effective

Query language allows quick answers to ad hoc queries

Provides better access to more and better-managed data

Promotes integrated view of organization’s operations

Reduces the probability of inconsistent data

Page 20: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

20

DBMS Manages Interaction

Page 21: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

21

Database Design

Importance of Good DesignPoor design results in unwanted data redundancyPoor design generates errors leading to bad decisions

Practical ApproachFocus on principles and concepts of database designImportance of logical design

Page 22: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

22

Database Models and the Internet

Characteristics of “Internet age” databases

Flexible, efficient, and secure Internet access

Easily used, developed, and supported

Supports complex data types and relationships

Seamless interfaces with multiple data sources and structures

Simplicity of conceptual database model

Many database design, implementation, and application development tools

Powerful DBMS GUI make DBA job easier

Page 23: 1 CSBP430 – Database Systems Chapter 1: Databases and Database Users Mamoun Awad College of Information Technology United Arab Emirates University Mamoun.awad@uaeu.ac.ae

23

When not to use a DBMS

Main inhibitors (costs) of using a DBMS:High initial investment and possible need for additional hardware.Overhead for providing generality, security, recovery, integrity, and concurrency control.

When a DBMS may be unnecessary:If the database and applications are simple, well defined, and not expected to change.If there are stringent real-time requirements that may not be met because of DBMS overhead.If access to data by multiple users is not required.

When no DBMS may suffice:If the database system is not able to handle the complexity of data because of modeling limitationsIf the database users need special operations not supported by the DBMS.