database system

15
By : Ashutosh Buxi Reg. No.: 0305203031 e-mail: [email protected]

Upload: sajan-sahu

Post on 17-Jul-2015

39 views

Category:

Technology


2 download

TRANSCRIPT

By :Ashutosh Buxi

Reg. No.: 0305203031e-mail: [email protected]

Has everyone noticed that all letters of the word database are typed with left hand? Now the layout of the QWERTY typewriter keyboard was designed, among other things, to facilitate the even use of both hands. It follows, therefore, that writing about databases is not only unnatural, but a lot harder than it appears.

Tight control of data redundancy. Enforces user-defined rules to ensure the integrity of table data. Has a centralized data dictionary for the storage of information pertaining to data and its manipulation. Ensures that the data can be shared across applications. Enforces data access authorization. Has automatic, intelligent backup and recovery procedure for data. Have different interfaces via which users can manipulate data.

Data redundancy and inconsistency

Difficulty in accessing data

Data isolation

Integrity problems

Atomicity problems

Concurrent-access anomalies

Security problems

Data Abstraction

Instances and Schemas

Data Independence

External Schema 1

External Schema 2

External Schema 3

Conceptual Schema

Physical Schema

Disk

Levels of Abstract ion in DBMS

sidsid namename loginlogin ageage gpagpa

53665366 JonesJones jones@csjones@cs 1818 3.43.4

53685368 SmithSmith smith@eesmith@ee 1818 3.23.2

53655365 GulduGuldu guldu@musicguldu@music 1212 2.02.0

Students (sid: string, name: string, login: string, age: integer, gpa: real)

An Instance of the Students Relation

Logical Data Independence

Physical Data Independence

Object-Based Logical Models

Social-security

Customer-name

Customer-street

Customer-city Account-number

balance

customer accountdepositor

A Sample E-R Diagram

Record-Based Logical Models The entity-relationship model

The object-oriented model

Relational Model

Network Model

Hierarchical Model

Record-Based Logical Models

customer-name social-security customer-street customer-city account-number

Jhonson 912-83-7465 Alma Palo Alto A-101

Smith 019-28-3746 North Rye A-215

Hayes 677-89-9011 Main Harrison A-102

account-number

balance

A-101 500

A-215 700

A-102 400

Jhonson

192-83-7465 Palo AltoAlma

Smith

Hayes

Lindsay

Turner

Jones

091-28-3746

677-89-9011

182-73-6091

321-12-3123

336-66-9999

North

Main

Putnam

Main

Park

Rye

Harrison

Stamford

Harrison

Pittsfield

A-101

A-222

A-215

A-102

A-305

A-201

A-217

500

700

400

350

900

750

700

A Sample Network Database

Jhonson 192-83-7465 …

Smith

Hayes

Lindsay

Turner

Jones

091-28-3746

677-89-9011

182-73-6091

321-12-3123

336-66-9999

A-101 A-222

A-215

A-102

A-305

A-201

A-217

500

700

400

350

900

750

700

A-201 900

A Sample of Hierarchical Database

Naive Users

Online Users

Application Programmers

Database Administrator

Design of the conceptual and physical schemas

Security and authorization

Data availability and recovery from failures

Integrity-constraint specification

Database tuning

Data Definition Language

Data Manipulation Language

Naïve users(tellers, agents,

etc.)

Application programmers

Sophisticated users

Database administrator

Application interface Application programs

Query Database scheme

indices Statistical data

Data dict ionaryData fi les

Application programs

object code

Embedded DML

precompiler

Query evaluation

engine

DML compiler

DDL interpreter

Transaction manager

Buffer manager

File manager

users

disk storage

Data base

management

system

query processor

storage manager

System Structure

Database procedure calls Precompiler

Modif ied application

program

HLL compiler

Application program

Compiled & optimized

versionLink editor Object module

Binary version of application program

OS & fi le subsystem

DBMS & data manager

Run-time system

Main memory

Processing Database Applicat ion in High-Level Language

DatabaseDBMS-user inter-

faceData

managerFile

managerDisk

manager

Response to user

Requested record

Requested block(s)

Block(s) from secondary storage

User’s query

Request specific record

Request specific block(s) Input/output

block(s)

Steps in Data Access

Reduction of redundancies

Shared data

Integrity

Security

Conflict resolution

Data independence

Problems associated with centralization

Cost of software/hardware and migration

Complexity of backup and recovery