Chapter 2 - Database System Model and Architecture
Chapter 2 - Database System Model and Architecture
Chapter Two
Database system Concepts and Architectures
2.1 Database Terminology
Any firm that gathers extensive amounts of information to be retrieved at some point in the future
depends on a file system (generally a database system) that allows for the access of specific information
in a timely and cost effective manner. This information is usually stored in files, records and fields.
A file is a set of related information stored together. It is a collection of information relative to a number
of related objects. For example, a bank needs to collect various types of information about customers,
employees, savings accounts, demand accounts, etc. Each one of these is a ‘subpackage’ of information,
stored as a file. They may have 4 files (Employee File, a Customer File, a Savings Account file and a
Demand Account file).
A record is a collection of information about an object. If we look at the example from above, the
Customer File, a record is a collection of information about a customer object. The record contains
information required by the bank about each customer, and stored for each customer. For example,
information contained in a customer record may include at least first_name, last_name, id_number,
birth_date. Each of these pieces of information are taken together to form a customer record. Because
each record in the file contain the same number and types of fields, the records have the same type.
A field is a piece of information about an entity, contained in a record. In the above example, the 4
pieces of information, first_name, last_name, id_number and birth_date are all fields. Therefore we can
use the following definitions, a record is a collection of related fields, and a file is a collection of related
records, of the same type.
Keys:- In most cases there is a field in a record that identifies that particular record uniquely. This field
is referred to as the primary key of the record. In some cases, there may not be a single field that
uniquely identifies a record and serve as the primary key. In these cases, a combination of two or more
fields can serve as the primary key. This is called a composite key.
Let’s assume there is a field for Customer Name. In this case, because it is likely that two customers will
have the same name, therefore duplicate values, Customer Name can’t be used as a primary key. This is
referred to as a secondary key. A secondary key is a field which identifies a record, but that does not
uniquely identify a record.
2) Network Model
The network model is the first one to be implemented by Honeywell in 1964-65 (IDS System). Adopted
heavily due to the support by CODASYL (CODASYL - DBTG report of 1971). Later implemented in a
large variety of systems - IDMS (Cullinet - now CA), DMS 1100 (Unisys), IMAGE (H.P.), VAX -
DBMS (Digital Equipment Corp).
The network model is a database model conceived as a flexible way of representing objects and their
relationships. Its distinguishing feature is that the schema, viewed as a graph in which object types are
nodes and relationship types are arcs, is not restricted to being a hierarchy or lattice. The nodes
corresponds to record types and the links to pointers or relationships. All the relationship are hardwired
or pre-computed and build into structure of database itself because they are very efficient in space
utilization and query execution time.
The network data structure looks like a tree structure except that a dependent node which is called a
child or member, may have more than one parent or owner node. The network model replaces the
hierarchical model with a graph thus allowing more general connections among the nodes. The main
difference of the network model from the hierarchical model is its ability to handle many to many
relationships. In other words it allow a record to have more than one parent.
A schema diagram displays only some aspects of a schema, such as the names of record types
and data items, and some types of constraints.
Other aspects are not specified in the schema diagram; for example, in the previous figure shows
neither the data type of each data item, nor the relationships among the various files.
Many types of constraints are not represented in schema diagrams.
For example a constraint such as students majoring in computer science must take CS1310
before the end of their sophomore year is quite difficult to represent diagrammatically.
Internal(physical) level: This lowest level of abstraction. it closest to physical storage device. It
describes how data are actually stored on the storage medium. The internal schema, which contains the
definition of the
he stored record, the method representing the data fields, expresses the internal view and
the access aids used.
ANSI-SPARC
SPARC Architecture and Database Design Phases
Data Independence
The three-schema architecture can be used to further explain the concept of data independence , which
can be defined as the capacity to change the schema at one level of a database system without having to
change the schema at the next higher level.
Application programs interact with the external database schema, which has an interface, or mapping, to
the conceptual schema. The conceptual schema is concerned with the identity and relationships between
elements of data of interest to an organization, and has an interface or mapping to the internal schema.
The internal schema controls how the data is stored on physical media, such as magnetic disks.
All the DBMS functionality, application program execution, and user inter-face processing were carried
out on one machine. The figure above illustrates the physical components in a centralized architecture.
Gradually, DBMS systems started to exploit the available processing power at the user side, which led to
client/server DBMS architectures.
Client-Server Architectures:
The client/server architecture was developed to deal with computing environments in which a large
number of PCs, workstations, file servers, printers, data-base servers, Web servers, e-mail servers, and
other software and equipment are connected via a network. The idea is to define specialized servers with
specific functionalities.
There are different client-server DBMS. This includes Specialized Servers with Specialized functions,
Clients and DBMS Server.
Specialized Servers with Specialized functions.
File Servers --- maintains the files of the client machines.
Printer Servers -- being connected to various printers; all print requests by the clients are
forwarded to this machine.
Web Servers and E-mail Servers also fall into the specialized server category
Clients:- The resources provided by specialized servers can be accessed by many client machines.
The client machines provide appropriate interfaces and a client-version of the system to access
and utilize the server resources as well as with local processing power to run local applications.
Clients maybe diskless machines or PCs or Workstations with disks with only the client software
installed. Others would have both client and server functionality.
Connected to the servers via some form of a network (LAN: local area network, wireless
network, etc.)
DBMS Server
A server is a system containing both hard-ware and software that can provide services to the
client machines, such as file access, printing, archiving, or database access.
Provides database query and transaction services to the clients
Sometimes called query and transaction servers
Two main types of basic DBMS architectures were created on this underlying client/server framework:
Two-tier client/server architecture
Three-tier client/server architecture
The architectures described here are called two-tier architectures because the software components are
distributed over two systems: client and server. The advantages of this architecture are its simplicity and
seamless compatibility with existing systems.