CoSc 265 FDMS - Chapter Two
CoSc 265 FDMS - Chapter Two
Fundamental of Database
management System
7
Example of a
Database Schema
Three-Schema Architecture
● Proposed to support DBMS characteristics
of:
○ Program-data independence.
Database ○ Support of multiple views of the data.
Defines DBMS schemas at three levels:
Architecture ● Internal schema
○ describe physical data storage structures and
access paths for the database (e.g indexes).
Typically uses a physical data model.
● Conceptual schema
○ describe the structure and constraints for the
whole database for a community of users.
○ Uses a conceptual or an implementation data
model.
● External schemas
○ describe the various user views.
○ Usually uses the same data model as the
conceptual schema.
Three-Schema Architecture
⚫ Defines DBMS schemas at three levels:
◦ Internal schema at the internal level to describe physical data
storage structures and access paths for the database (e.g
indexes).
● Typically uses a physical data model.
◦ Conceptual schema at the conceptual level to describe the
structure and constraints for the whole database for a
community of users.
● Uses a conceptual or an implementation data model.
◦ External schemas at the external level to describe the various
user views.
● Usually uses the same data model as the conceptual schema. 10
The three-schema
architecture
● Logical Data Independence:
○ The capacity to change the conceptual
schema without having to change the
external schemas and their associated
application programs.
DBMS Languages
monitor or terminal or to be embedded
in a general-purpose programming
language
■ For example, the SQL relational
language
■ Are “set-at-a-time” or “set-oriented”
■ Also called declarative languages.
○ Low Level or Procedural Language:
■ Low level DML must be embedded in
general-purpose programming
language
■ Retrieve data one record-at-a-time;
■ Constructs such as looping are
needed to retrieve multiple records,
along with positioning pointers.
■ Low-level DMLs are also called record-
at-a-time
● Stand-alone query language interfaces
○ Example: Entering SQL queries at the DBMS
interactive SQL interface (e.g. SQL*Plus in
ORACLE)
● Programmer interfaces for embedding DML in
20
● There is a dedicated client and server machine in this
system.
● Client
○ Provide appropriate interfaces through a client
software
○ Clients may be diskless machines or PCs or
Client-Server Workstations with disks with only the client
software installed.