Class 05
Class 05
Database Systems:
Over the past 50 years, a number of different
approaches or models have represented accounting
information systems. Each new model evolved
because of the shortcomings and limitations of its
predecessor. An interesting feature in this evolution
is that the newest technique does not immediately
replace older models. Thus, at any point in time,
various generations of systems exist across different
organizations and may even coexist within a single
enterprise.
Database Systems
The modern auditor needs to be familiar with
the operational features of all AIS approaches
that he or she is likely to encounter. This chapter
deals with four such models:
❖ The Manual processes,
❖ The Flat-file systems,
❖ The database approach,
❖ The database management system.
The Manual process model
The manual process model is the oldest and most
traditional form of accounting systems. Manual systems
constitute the physical events, resources, and
personnel that characterize many business processes.
This includes such tasks as order-taking, warehousing
materials, manufacturing goods for sale, shipping goods
to customers, and placing orders with vendors.
This model also includes the physical task of record
keeping that is manually. Manual procedures facilitate
to understand the internal control activities, including
segregation of functions, supervision, independent
verification, audit trails, and access controls.
The Flat-File Model
The flat-file approach is most often associated
with so-called legacy systems (outdated
systems). These are large mainframe systems
that were implemented in the late 1960s
through the 1980s.
Organizations today still use these systems
extensively. The flat-file model describes an
environment in which individual data files are
not related to other files. End users in this
environment own their data files rather than
share them with other users.
Many so-called legacy (outdated) systems are
characterized by the flat-file approach to data
management. In this environment, users own their
data files. Exclusive ownership of data is a natural
consequence of two problems associated with the
legacy-system era.
➢ The first is a business culture that erects barriers
between organizational units that inhibit entity-
wide integration of data.
➢ The second problem stems from limitations in
flat-file management technology that require
data files to be structured to the unique needs of
the primary user.
Figure: Flat-File Data Management
Flat-File Data Management
In the above figure, the file contents are represented
conceptually with letters. Each letter could signify a single
data attribute (field), a record, or an entire file. Note also
that data element B is present in all user files. This is
called data redundancy and is the cause of three types of
data management problems:
(1) Data storage,
(2) Data updating, and
(3) Currency of information.
Each of these, as well as a fourth problem, task-data
dependency, which is not directly related to data
redundancy will be examined next.
The Database Approach
The most obvious change from the flat-file model is
the pooling of data into a common database that is
shared by all the users. Thus flat-file problems
solved, because data sharing (the absence of
ownership) is the central concept of the database
approach. The followings are characteristics of
database:
▪ No data redundancy
▪ Single update
▪ Current values
▪ Task-data independence
The Database Management System
The purpose of the DBMS is to provide
controlled access to the database. The DBMS is
a special software system that is programmed to
know which data elements each user is
authorized to access. The user’s program sends
requests for data to the DBMS, which validates
and authorizes access to the database in
accordance with the user’s level of authority.
The DBMS will deny requests for data that the
user is unauthorized to access.
Difference between File system & DBMS
File system DBMS
1. File system is a collection of data. Any 1. DBMS is a collection of data and
management with the file system, user has user is not required to write the
to write the procedures procedures for managing the
2. File system gives the details of the data database.
representation and Storage of data. 2. DBMS provides an abstract view of
3. In File system storing and retrieving of data data that hides the details.
cannot be done efficiently. 3. DBMS is efficient to use since there
4. Concurrent access to the data in the file are wide varieties of sophisticated
system has many problems like a. Reading techniques to store and retrieve
the file while other deleting some the data.
information, updating some information 4. DBMS takes care of Concurrent
5. File system doesn’t provide crash recovery access using some form of locking.
mechanism. Eg. While we are entering some 5. DBMS has crash recovery
data into the file if System crashes then mechanism, DBMS protects user
content of the file is lost. from the effects of system failures.
6. Protecting a file under file system is very 6. DBMS has a good protection
difficult mechanism.
Data Independence
Data independence can be defined as the capacity
to change the schema at one level without changing
the schema at next higher level. There are two
types of data Independence. They are :
1. Logical data independence.
2. Physical data independence.
❖ Logical data independence is the capacity to
change the conceptual schema without having to
change the external schema.
❖ Physical data independence is the capacity to
change the internal schema without changing the
conceptual schema.
When 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.
▪ 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.
Types of Databases and Database Applications
❑ Traditional Applications:
Numeric and Textual Databases
❑ More Recent Applications:
Multimedia Databases
Geographic Information Systems (GIS)
Data Warehouses
Real-time and Active Databases
Many other applications
Data Model
A model is an abstraction process that hides
superfluous details. Data modeling is used for
representing entities of interest and their
relationship in the database. Data model is a
collection of concepts that can be used to
describe the structure of a database which
provides the necessary means to achieve the
abstraction. The structure of a database means
that holds the data.
Types of Data Models
What is Schema?
Schema is the overall description of the database. The basic
structure of how the data will be stored in the database is
called schema. In DBMS, the term schema refers to the
architecture of the database which describes how it will
appear or will be constructed. It describes the organization of
data such as tables, relationships as well as constraints. A
schema is a template that dictates how data items in a
database will be stored, arranged, and accessed.
Example
Let’s say a table teacher in our database named
school, the teacher table requires the name,
dob, and doj in their table so we design a
structure as:
Teacher table
Name: String
Doj: date
Dob: date
Types of Schema
Schema Instance
It is the overall description of the It is the collection of information
database. stored in a database at a particular
moment.
The schema is same for the whole Data in instances can be changed
database. using addition, deletion, and
updating.
Does not change Frequently. Changes Frequently.
Affects the entire database structure. Affects only the current state of data.
Requires significant effort and Easily altered by
planning to change. performing CRUD (Create, Read,
Update, Delete) operations.
Table structures, relationships, Data entries, records in tables.
constraints.
DBMS Languages
• A DBMS has appropriate languages and
interfaces to express database queries and
updates.
• Database languages can be used to read, store
and update the data in the database.
Types of Database Languages
Data Definition Language (DDL)
• DDL stands for Data Definition Language. It is used to
define database structure or pattern.
• It is used to create schema, tables, indexes, constraints, etc.
in the database.
• Using the DDL statements, you can create the skeleton of
the database.
• Data definition language is used to store the information of
metadata like the number of tables and schemas, their
names, indexes, columns in each table, constraints, etc.
Resources Events
Agents(Entities)