Top Banner
Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010
56

Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Dec 29, 2015

Download

Documents

John Smith
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Course Introduction

Ria Mae G. CordaITB322 (Lecture)

2nd Semeseter, AY 2009 - 2010

Page 2: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Outline

Introducing the database and related terms A REAL LIFE example The database approach The database actors

Page 3: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Outline

Behind the scene The DBMS advantage When NOT to use DBMS Summary

Page 4: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Traditional Database Applications– Information is stored textually or numerically

Multimedia Database Applications– Images, audio clips and video streams can be

stored– Geographic information systems– Data warehouses– Online analytical processing (OLAP)– Real-time/Active database technology

Page 5: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Database– Collection of related data

Data– Known facts– Can be recorded– Have implicit meaning

Page 6: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Properties of a database– Represents some aspect of the real world– Logically coherent collection of data with inherent

meaning– Designed, built and populated for a specific

purpose

Page 7: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

A database may be maintained manually or it may be computerized– In this course we are only concerned about

computerized databases– A computerized database may be created an

manipulated using application programs or by a database management system

Page 8: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Database Management System (DBMS)– A collection of programs that enables users to

create and maintain a database– A general-purpose software system that facilitates

the processes of defining, constructing, manipulating, and sharing databases among various users and applications

Page 9: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Defining a database– Involves specifying the data type, structures,

and constraints of the data to be stored in the database.

– The database definition is also stored in the database

Meta-data is the database catalog or dictionary

Page 10: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Constructing the database– The process of storing the data on some storage

medium controlled by the DBMS

Page 11: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Manipulating a database– Includes querying the database for information

retrieval, updating the database to reflect changes in the real world, and generating reports from the data.

Page 12: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Sharing a database– Allows multiple users and programs to access the

database simultaneously.

Page 13: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Application program– Accesses the database by sending queries or

requests for data to the DBMS

Page 14: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Query– Typically causes for some data to be retrieved.

Transaction– Causes some data to be read and some data to

be written into the database.

Page 15: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

Protection– System protection against hardware or software

malfunction,– Security protection against unauthorized or

malicious access.

Maintenance– Allowing the system to evolve as requirements

change over time

Page 16: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Introducing the database and related terms

It is not necessary to use general-purpose DBMS software to implement a computerized database.

Database system– The database and the DBMS software together

Page 17: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

A REAL LIFE example

The SCENARIO– A UNIVERSITY database for maintaining

information concerning students, courses, and grades in a university environment

– Has five files: STUDENT, COURSE, SECTION, GRADE_REPORT, PREREQUISITE

Page 18: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

A REAL LIFE example

Defining the database– We must define the data types of each data

element in each record

Page 19: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

A REAL LIFE example

Constructing the database– We store the data regarding each student,

course, section, grade report, and prerequisite

Page 20: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

A REAL LIFE example

Manipulating the database– Involves querying and updating– Example: retrieving the transcript, changing

sections, creating a new course, etc

Page 21: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

A REAL LIFE example

Requirements definition and analysis– Identifying business rules and needs

Conceptual design– A model of the requirements to be able to

transform it into a database implementation

Page 22: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

A REAL LIFE example

Logical design– Expression of the model in a DBMS software

implementation

Physical design– Specifications for physical storage and access of

the database

Page 23: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

File-processing system vs. database system

File Processing System Database System

Each user defines and implements the files needed for the application

A data repository is defined once then accessed by various users

Each application is free to name data elements independently

The names and labels of data are defined one

Page 24: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Self-describing nature of a database system– The database system does not just contain the

database itself but even the database definition called meta-data

– Should work with any number of database applications as long as the database definition is available

Page 25: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Insulation between programs and data, and data abstraction– DBMS access programs do not require changing

all programs that access the database when a structural change happens (program-data independence)

Page 26: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Insulation between programs and data, and data abstraction– User application programs can operate on the

data by invoking operations regardless of how the operation is implemented (program-operation independence)

Operation is a function or method made up of– Interface which contains the name and parameters– Implementation which defines the operation

Page 27: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Insulation between programs and data, and data abstraction– Data abstraction

Characteristic that allows program-data independence and program-operation independence

Data model is a type of data abstraction– Hides storage and implementation details that are not of

interest to most database users

Page 28: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Support of multiple views of the data– Although there is a single repository of data, only

a subset of this data may be made available to a particular set of users

A view is virtual data derived from the database but not explicitly stored

Page 29: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Sharing of data and multi-user transaction processing– Transaction

An executing program or process that includes one or more database accesses such as reading or updating the database

Needs to have concurrency control, isolation, and atomicity

Page 30: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database approach

Sharing of data and multi-user transaction processing

– Concurrency control Ensures that several users trying to update the same data do

so in a controlled manner– Isolation

Ensures that each transaction appears to execute in isolation from other transactions

– Atomicity Ensures that either all the database operations in a transaction

are executed or none are.

Page 31: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

Database administrators (DBA)– A chief administrator to oversee and manage the

database, the DBMS, and other related software.– Responsible for:

authorizing access to the database coordinating and monitoring its use, and acquiring software and hardware resources as needed.

– Accountable for breach of security or poor system response time.

Page 32: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

Database designers– Responsible for

Identifying the data to be stored in the database Choosing appropriate structures to represent and store

data Communicating to prospective database users to

understand the requirements Creating a design that fits user requirements

– Final database design must be capable of supporting the requirements of ALL user groups

Page 33: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

End users– Casual end users

Occasionally access the database May need different information every time Use sophisticated query language to specify their

requests Typically management level

Page 34: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

End users– Naïve or parametric end users

Make up the sizeable portion of database end users Constantly querying and updating the database Use canned transaction

– Standard types of queries and updates Examples: bank tellers, reservation clerks, cashiers

Page 35: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

End users– Sophisticated end users

Engineers, scientists, business analysts– Thoroughly familiarize themselves with the DBMS facilities

to implement their applications

Page 36: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

End users– Standalone users

Maintain personal databases– Uses ready-made program packages that provide easy-to-

use menu-based or graphics-cased interfaces.

Page 37: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

End users

User Level of DBMS expertise

Casual Minimal

Naïve or parametric Minimal

Sophisticated Very high

Standalone Proficient in using a specific software package

Page 38: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The database actors

System analysts and application programmers– System analyst

Determine the requirements of end users Develop specifications for canned transactions that

meet these requirements

– Application programmer Implement the specifications as programs Also tests, debugs, documents and maintains

– Also known as software engineers/developers

Page 39: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Behind the scene

Other personnel are associated with the design, development, and operation of the DBMS software itself and the system environment surrounding it

They are instrumental in making the database system available to end users but do not use the database for their own purpose

Page 40: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Behind the scene

DBMS system designers and implementers– Design and implement the DBMS modules and

interfaces as a software package– Ensures that the DBMS can interface with

operating systems and programming language compilers

Page 41: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Behind the scene

Tool developers– Design and implement tools

Tools are software packages that facilitate database modeling and design, database system design, and improved performance.

– Often purchased separately

Page 42: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

Behind the scene

Operators and maintenance personnel– System administration personnel– Responsible for the actual running and

maintenance of hardware and software environment for the database system

Page 43: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Controlling redundancy– Redundancy is storing the same data multiple

times which leads to Duplication of effort Waste of storage space Data inconsistency

– Should allow controlled redundancy in some cases

Page 44: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Restricting unauthorized access– A database system should have a security and

authorization subsystem– Only certain people can be given privilege to

access confidential data at different levels

Page 45: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Providing persistent storage for program objects– Persistency

Ability of data to survive even after the program is terminated to enable later access of other programs.

Page 46: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Providing storage structures for efficient query processing– Indexes

Data structures that allow efficient disk search

– Buffering module Provided by the DBMS to maintain parts of the database

in the main memory

– Query processing and optimization module Enables the choosing of an efficient query execution

plan based on existing storage structures

Page 47: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Providing backup and recovery– The DBMS should have a recovery facility to

Restore the database in a state before a system failure occurred

Resume the transaction from the point where it was interrupted

Page 48: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Providing multiple user interfaces– A DBMS should be able to provide:

Query languages for casual users Programming language interfaces for application

programmers Forms and command codes for parametric users Menu-driven interfaces and natural language interfaces

for standalone users

– Graphical user interface (GUI) can be forms-style or menu-style

Page 49: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Representing complex relationships among data– The DBMS must have the capability to

Represent complex relationships among the data Define new relationships as they arise Retrieve and update related data easily and efficiently

Page 50: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Enforcing integrity constraints– Integrity constraints

Rules that must hold for the data Example: data type, uniqueness of data

– Some constraints can be specified to the DBMS and automatically enforced

– Others can be checked by the update programs or the applications during data entry

Page 51: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Permitting inferencing and actions using rules– Deductive database systems

A DBMS which provides capabilities for defining deduction rules for inferencing new information from the stored database facts

– Triggers A form of a rule activated by updates to the table, which

results to operations on other tables, sending messages, etc.

Page 52: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Permitting inferencing and actions using rules– Stored procedures

Become a part of the overall database definition Invoked when conditions are met

– Active database systems Provide active rules that can automatically initiate

actions when certain events and conditions occur

Page 53: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

The DBMS Advantage

Some added advantages– Potential for enforcing standards– Reduced application development time– Flexibility– Availability of up-to-date information– Economies of scale

Page 54: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

When NOT to use DBMS

Database overhead costs– Initial investment in hardware, software, and

training– Generality for defining and processing data– Overhead for providing security, concurrency

control, recovery, and integrity functions

Page 55: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

When NOT to use DBMS

Circumstances where DBMS is not ideal– Simple, well-defined database applications NOT

expected to change– Stringent, real-time requirements– No multiple-user access to data

Page 56: Course Introduction Ria Mae G. Corda ITB322 (Lecture) 2 nd Semeseter, AY 2009 - 2010.

When NOT to use DBMS

Industries which do not use general-purpose DBMS– Computer-aided design (CAD) tools– Communication and switching systems– Geographical information systems (GIS)