chapter 1 databases & database users. slide 1-2 acknowledge the main reference of this...

32
Chapter 1 Databases & Database Users

Upload: amice-collins

Post on 12-Jan-2016

229 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Chapter 1Databases & Database Users

Page 2: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-2

AcknowledgeThe main reference of this presentation is the textbook and PPT from : Elmasri & Navathe, Fundamental of Database Systems, 4th edition, 2004, Chapter 1Additional resources: presentation prepared by Prof Steven A. Demurjian, Sr (http://www.engr.uconn.edu/%7Esteve/Cse255/cse255.html)

Page 3: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-3

Overview of MaterialsWhat is a database? What is a database system?What is a DBMS?When is a database system needed?Motivating database managementCharacteristic of database approachDatabase usersAdvantages of using DBMS approachA brief history of database applicationWhen not to use a DBMS

Page 4: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-4

What is a database? Example of database application:

Banks, Hospital, etc

Extensions: Multimedia databases Geographic Information Systems Data warehouse On-line analytical processing (OLAP) Active & real-time databases etc

Page 5: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-5

What is a database? (cont)Basic definition: 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 6: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-6

Properties of database Represents some aspect of the real

world, called miniworld or Universe of Discourse

Logically coherent collection of data with some inherent meaning

Designed, built and populated for specific purpose

Page 7: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-7

What is a database system?

Page 8: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-8

When is a database system needed?When is a database system needed?ExamplesExamples

Typical EnvironmentTypical Environment Corporate EnterpriseCorporate Enterprise Data With Large Homogenous Parts (e.g., Formatted Data With Large Homogenous Parts (e.g., Formatted

Data)Data) Data Relevant Over a Long TimeData Relevant Over a Long Time Data Used by Many Simultaneous Users (Batch and Data Used by Many Simultaneous Users (Batch and

On-line Users) for Retrieval & UpdateOn-line Users) for Retrieval & Update

Page 9: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-9

What is a DBMS?Database Management System is a general purpose software system that facilitates the process of

defining, constructing and manipulating

database for various applications

Page 10: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-10

Main functions of DBMS Defining a Database:

Specifying Data Types, Structures, and Constraints

Constructing a Database: the Process of Storing the Data Itself on Some Storage Medium

Manipulating a Database: Function for Querying Specific Data in the Database and Updating the Database

Page 11: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-11

Additional functions of DBMS

Interaction with File ManagerSo that Details Related to Data Storage and Access

are Removed From Application Programs Integrity Enforcement

Guarantee Correctness, Validity, Consistency Security Enforcement

Prevent Data From Illegal Uses Concurrency Control

Control the Interference Between Concurrent Programs

Recovery from Failure Query Processing and Optimization

Page 12: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-12

Motivating database management

Manual Database Management Data are Not Stored Programmer Defines Both Logical Data Structure and

Physical Structure (Storage)

Page 13: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-13

File Processing Data are Stored in Files with Interface Between Programs and

Files. Various Access Methods Exist (E.G., Sequential, Indexed,

Random) One File Corresponds to One or Several Programs.

Motivating database management

Page 14: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-14

Problems with file systems Data are Still Highly Redundant

Sharing Limited and at the File Level Data is Unstructured

“Flat” Files High Maintenance Costs

Data Dependence Ensuring Data Consistency and Controlling Access to Data

(Concurrent Access Problematic) Difficult to Understand by New Developers

Difficulties in Developing New Applications Almost Impossible to Evolve with New Capabilities Risk of Inefficient Applications

Page 15: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-15

Database Database vs. vs. File SystemFile System

Coordinates Both Physical Coordinates Both Physical and Logical Access to the and Logical Access to the DataData

Data are Shared by All Data are Shared by All Programs Authorized to Programs Authorized to Have Access to ItHave Access to It

Flexible Access to Data Flexible Access to Data (i.e., Queries)(i.e., Queries)

Multiple Users Accessing Multiple Users Accessing the Same Data at Same the Same Data at Same TimeTime

Coordinates Only the Coordinates Only the Physical Access to the Physical Access to the DataData

Data Written by One Data Written by One Program May Not Be Program May Not Be Readable by Another Readable by Another ProgramProgram

Pre-determined Access to Pre-determined Access to Data (I.E., Compiled Data (I.E., Compiled Programs)Programs)

No Two Programs Can No Two Programs Can Concurrently Access the Concurrently Access the Same FileSame File

Page 16: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-16

‘‘University’ database exampleUniversity’ database example

Has 5 files (‘tables’): Has 5 files (‘tables’): StudentStudent CourseCourse SectionSection Grade ReportGrade Report PrerequisitePrerequisite

See how do they relate to each other!See how do they relate to each other!

How do we define, construct & manipulate?How do we define, construct & manipulate?

Page 17: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-17

Page 18: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-18

Characteristic of Database Characteristic of Database ApproachApproach

Self-describing natureSelf-describing nature

Insulation between program and dataInsulation between program and data

Support of multiple views of dataSupport of multiple views of data

Sharing of data & multiuser transaction Sharing of data & multiuser transaction processingprocessing

Page 19: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-19

Self-describing natureSelf-describing nature

As oppose to unstructured dataAs oppose to unstructured data

Contains not only database itself, but Contains not only database itself, but also a complete definition of database also a complete definition of database structure (metadata)structure (metadata)

In traditional file processing, data In traditional file processing, data definition is part of the application definition is part of the application programprogram

Page 20: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-20

Insulation between programs & Insulation between programs & datadata

Changes to the data structure does not Changes to the data structure does not generally require changing the programgenerally require changing the program

For example, adding a new field ‘Birthday’For example, adding a new field ‘Birthday’

The ‘data structure’ is not in the programThe ‘data structure’ is not in the program

We call this program-data independenceWe call this program-data independence

DBMS provides DBMS provides conceptual representationconceptual representation

User or programmer does not need to know User or programmer does not need to know how the DBMS store the data in the disk / file.how the DBMS store the data in the disk / file.

Page 21: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-21

Multiple Views Many users, different needs

Accessing & printing the transcript of each students

Checking that students have taken all the prerequisite course

Page 22: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-22

Sharing & MultiuserSharing & Multiuser

DBMS provides concurrency control to DBMS provides concurrency control to ensure ‘correct’ behavior when multiple ensure ‘correct’ behavior when multiple users access the same databaseusers access the same database

Example: airline seat reservationExample: airline seat reservation

It is called On-Line Transaction It is called On-Line Transaction Processing (OLTP)Processing (OLTP)

Page 23: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-23

Database usersDatabase usersActors on the SceneActors on the Scene

Database administratorDatabase administrator Authorizing access rightsAuthorizing access rights

Database designersDatabase designers Defines the structure of data to be storedDefines the structure of data to be stored

End users:End users: Casual end userCasual end user Naïve/parametric userNaïve/parametric user Sophisticated usersSophisticated users Stand-alone usersStand-alone users

System analyst and Application System analyst and Application programmers programmers (software engineers)(software engineers)

Page 24: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-24

Database usersDatabase users

Workers behind the SceneWorkers behind the Scene DBMS system designers and implementersDBMS system designers and implementers Tool developersTool developers Operators and maintenance personnelOperators and maintenance personnel

Page 25: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-25

Advantages of Using a DBMSAdvantages of Using a DBMS

Controlling redundancyControlling redundancy

Restricting unauthorized accessRestricting unauthorized access

Provides persistent storage for data Provides persistent storage for data structuresstructures

Permits inference & actions using rulesPermits inference & actions using rules

Multiple user interfacesMultiple user interfaces

Represents complex relations amongst dataRepresents complex relations amongst data

Enforcing integrity constraintsEnforcing integrity constraints

Provides backup & recoveryProvides backup & recovery

Page 26: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-26

Additional Implications of Using Additional Implications of Using the Database Approachthe Database Approach

Potential for enforcing standards: this is very crucial for the success of database applications in large organizations Standards refer to data item names, display formats, screens, report structures, meta-data (description of data) etc.

Reduced application development time: incremental time to add each new application is reduced.

Page 27: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-27

Additional Implications of Using Additional Implications of Using the Database Approachthe Database Approach

Flexibility to change data structures: database structure may evolve as new requirements are defined.

Availability of up-to-date information – very important for on-line transaction systems such as airline, hotel, car reservations.

Economies of scale: by consolidating data and applications across departments wasteful overlap of resources and personnel can be avoided.

Page 28: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-28

Historical Development of Database Historical Development of Database TechnologyTechnology

Early Database Applications: The Hierarchical and Network Models were introduced in mid 1960’s and dominated during the seventies. A bulk of the worldwide database processing still occurs using these models.Relational Model based Systems: The model that was originally introduced in 1970 was heavily researched and experimented with in IBM and the universities. Relational DBMS Products emerged in the 1980’s.

Page 29: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-29

Historical Development of Database Historical Development of Database TechnologyTechnology

Object-oriented applications: OODBMSs were introduced in late 1980’s and early 1990’s to cater to the need of complex data processing in CAD and other applications. Their use has not taken off much.Data on the Web and E-commerce Applications: Web contains data in HTML (Hypertext markup language) with links among pages. This has given rise to a new set of applications and E-commerce is using new standards like XML (eXtended Markup Language).

Page 30: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-30

Extending Database CapabilitiesExtending Database CapabilitiesNew functionality is being added to DBMSs in the following areas:

Scientific Applications Image Storage and Management Audio and Video data management Data Mining Spatial data management Time Series and Historical Data

ManagementThe above gives rise to new research and development in incorporating new data types, complex data structures, new operations and storage and indexing schemes in database systems.

Page 31: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-31

When not to use a DBMSWhen 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,

concurrency control, recovery, and integrity functions.

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.

Page 32: Chapter 1 Databases & Database Users. Slide 1-2 Acknowledge The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,

Slide 1-32

When not to use a DBMSWhen not to use a DBMS

When no DBMS may suffice: If the database system is not able to handle the

complexity of data because of modeling limitations If the database users need special operations not

supported by the DBMS.