Database Systems Concepts: Introduction To Databases
Database Systems Concepts: Introduction To Databases
Database Systems Concepts: Introduction To Databases
Introduction to Databases
Objectives
Some common uses of database systems. Characteristics of file-based systems. Database and Database Management System (DBMS). Advantages and disadvantages of DBMSs.
File-Based Systems
Collection of application programs that perform services for the end users (e.g. reports). Each program defines and manages its own data.
File-Based Processing
Duplication of data
Same data is held by different programs. Wasted space and potentially different values and/or different formats for the same item.
6
Database Approach
Arose because:
Definition of data was embedded in application programs, rather than being stored separately and independently. No control over access and manipulation of data beyond that imposed by application programs.
Result:
the database and Database Management System (DBMS).
Database
Shared collection of logically related data (and a description of this data), designed to meet the information needs of an organization.
(Database) application program: a computer program that interacts with database by issuing an appropriate request (SQL statement) to the DBMS.
10
11
Database Approach
Controlled access to database may include:
a security system an integrity system a concurrency control system a recovery control system a user-accessible catalog.
12
13
Software
DBMS, operating system, application programs.
Data
and a description of this data (schema)
Procedures
Instructions and rules that should be applied to the design and use of the database and DBMS.
People
14
15
Advantages of DBMSs
Control of data redundancy Data consistency More information from the same amount of data Sharing of data Improved data integrity Improved security Enforcement of standards Economy of scale
16
Advantages of DBMSs
Balance conflicting requirements Improved data accessibility and responsiveness Increased productivity Improved maintenance through data independence Increased concurrency Improved backup and recovery services
17
Disadvantages of DBMSs
Complexity Size Cost of DBMS Additional hardware costs Cost of conversion Performance Higher impact of a failure
18
19
22
Conceptual Level
Community view of the database. Describes what data is stored in database and relationships among the data.
23
24
25
Data Independence
Logical Data Independence
Refers to immunity of external schemas to changes in conceptual schema. Conceptual schema changes (e.g. addition/removal of entities). Should not require changes to external schema or rewrites of application programs.
26
Data Independence
Physical Data Independence
Refers to immunity of conceptual schema to changes in the internal schema. Internal schema changes (e.g. using different file organizations, storage structures/devices). Should not require change to conceptual or external schemas.
27
28
Database Languages
Data Definition Language (DDL)
Allows the DBA or user to describe and name entities, attributes, and relationships required for the application plus any associated integrity and security constraints.
29
Database Languages
Data Manipulation Language (DML)
Provides basic data manipulation operations on data held in the database.
Procedural DML
allows user to tell system exactly how to manipulate data.
Non-Procedural DML
allows user to state what data is needed rather than how it is to be retrieved.