Download as pdf or txt
Download as pdf or txt
You are on page 1of 33

Accounting

Information Systems
Week 3:
Database Concepts

Jim Lim
Assistant Professor

UBSS Sydney CBD Campus


Level 10 & 11 233 Castlereagh Street
Sydney NSW2000

1-1
Database Concepts (Ch 3)
1. Role of database in decision making
2. Database concepts
3. Data redundancy
4. Database systems & functions
5. Database modelling, design and
implementation of relational databases

1-2
1-3
1. Role of Database in decision making
• Database - an organized collection of data, generally stored and accessed
electronically
• Database system enables all data of organisation contained within one system
• Example, inventory data levels updated in system by inventory department
• Staff members across all departments can access same information
➢ Sales staff want to know how much inventory available for customers,
➢ Accounts receivable staff want to know how much inventory customers have purchased on credit.

• Using database system, both employees could access same information for own
purposes.

1-4
1. Role of Database in decision making
• Managers require accurate, relevant and timely information to make
strategic and operational decisions.
• Examples
➢ Continue manufacturing and selling an existing product (strategic decision)?
➢ Invest in new plant and equipment (strategic decision)?

➢ Stop production and service machinery because reports show increasing number of
defects from production (operating decision)?

1-5
1. Role of Database in decision making
• Data is not information
• Data is stored in databases and information is derived from data
• Database (or database system) is a computerised software program enabling
data to be captured and stored
• Information, therefore, is derived from facts or data processed in a meaningful
form.
• Meaningful information is derived by capturing, storing and managing data
efficiently and effectively.

1-6
1. Role of Database in decision making
Database Tutorial for Beginners

1-7
1. Role of Database in decision making
Database models

1-8
1. Role of Database in decision making

Design of database models in relational databases


• Database models is collection of logical constructs used to
represent data structure and data relationships found within
database.
• Four models: external models, conceptual models,
implementation models and physical models.

1-9
1. Role of Database in decision making
Design of database models in relational databases
• External model is end-users’ views of data.
• End-users are different groups in organisation such as marketing,
accounting, accounts payable or accounts receivable.
• Each external users use different aspects of database to perform their
decision making and reporting.
• All different aspects required in database are combined to form
conceptual model.

1-10
1. Role of Database in decision making

• Conceptual model uses entity-relationship diagram to show


relationships in system.
• Focus on logical view of what is represented in database.
• Conceptual model is independent of hardware and software
• This model shows relationships as being one-to-one, one-to-
many and many-to-many.

1-11
1. Role of Database in decision making
• Therefore, there is a process through which conceptual models are
converted into implementation models.
• Implementation models are what can be installed on a computerised
database program.
• Conceptual models cannot be installed on a computerised database
package
• However, first step in modelling an organisation’s data requirements.

1-12
1. Role of Database in decision making
• Implementation model covered in detail in section 5.
• Physical model includes some physical aspects required to implement a
system.
• Physical representation of client–server model shows all specifications of
hardware and software.
• Therefore, there is a process in designing a database, from external
model to conceptual model to implementation model!

1-13
2. Database concepts
• Various types of database but . . .
• Most common is Relational database.
• Relational database uses entities (or tables) and shows
relationships between tables.
• Relational database is a collection of carefully defined tables.

1-14
2. Database concepts
Example of a file – ‘Customer File’ or “Entity”

Primary Key

Note: In relational databases, possible to search and query on all attributes i.e. no need focus just on primary keys.

1-15
2. Database concepts
• Relational database stores data in a number of tables.
• Table is collection of columns (attributes) and rows (objects) that
describe an entity.
• Record consists of set of fields that describe a person, place or thing
• Fields describe a particular characteristic of each record, such as a name,
address or phone number derived from data or facts.

1-16
2. Database concepts
• File is a collection of records that are related.
• Primary key: an attribute (or column) that uniquely identifies a particular
object (or row).
• Composite key: a combination of more than one primary key.

1-17
3. Data redundancy
• Data redundancy occurs when same data is stored in multiple locations
in an organisation
• Data redundancy can lead to data inconsistency and anomalies (see next
slide)
• Example, Sales and Marketing teams have same information in separate
database

1-18
3. Data redundancy
• Data anomalies are inconsistencies or errors in database because of
entry or change errors.
• Examples . . .
➢ Modification anomalies: occurs when a field is changed e.g. new customer address
incorrectly input.
➢ Insertion anomalies: occurs when new customers are entered into customer file and
assigning to wrong Sales person.
➢ Deletion anomalies: occurs when salesperson resigns/terminated from organisation and
customer records not updated or deleted with new salesperson.

1-19
4. Database Systems & Functions
• Database system (database) is a collection of elements that capture, store, manage
and use data within a database environment e.g. hardware, software, DBMS, people,
procedures and data.
• Database management system (DBMS) is a group of programs that manipulate
database and provide interface between database and user as well as other
application programs.
• Procedures are the instructions and rules that govern the design and use of the
database system for the organisation.

1-20
4. Database Systems & Functions
Elements of database system: DBMS, data, application programmes, hardware, people (database
administrator, database designers, analyst, programmers) and procedures.

1-21
4. Database Systems & Functions
Advantages of Database System
➢Eliminates data repetition
➢Eliminates inconsistent data
➢Allows for organisational wide data sharing
➢Reduced program maintenance
➢Increased flexibility & speed
➢Improves system security

1-22
4. Database Systems & Functions
The DBMS function in a typical database system

1-23
4. Database Systems & Functions
DBMS useful functions include . . .
➢ Data dictionary
➢ Data storage management
➢ Data transformation and presentation
➢ Security management
➢ Multi-user access control
➢ Backup and recovery management
➢ Data integrity management
➢ Access language and application programming interfaces
➢ Communication interfaces

1-24
4. Database Systems & Functions
DBMS useful functions include . . . (details)

• Data Dictionary contains a definition of data elements & their relationship with one another e.g. date, day, month “dd/mm/yy”.

• Data storage management helps to manage capture of inputs, and application of business rules, codes and structures to those inputs, so that
they can be transformed and stored e.g. videos and pictures.

• Data transformation and presentation allows entered data to conform to existing data structure i.e. translates requests into commands that
store, locate and retrieve requested data.

• Security management: enforces user security and data privacy within the database.

• Multiuser access control: providers data integrity & consistency to many users simultaneously without compromising integrity of database.

• Backup and recovery management contains procedures that perform routine and special backup and restorations in case of database failure

• Access language and application programming interfaces all database to be queried using query language e.g. SQL (Structured Query Language)

• Communication interfaces such as Internet Explorer allows database to accept end user requests within network environment.

1-25
5. Database modelling, design and implementation of relational databases

• Database modelling and design are first two steps in describing complex
real-world activities captured by and represented in a database system.
• Two steps to this process: design of conceptual model and design of
implementation model.

1-26
5. Database modelling, design and implementation of relational databases

• Conceptual models . . .
➢ focus on a logical view of what is represented in the database i.e. entity–
relationship model
➢ is logical representation (or view) independent of hardware and software.

• Implementation models show how data are represented in a database


product e.g. Microsoft Access

1-27
5. Database modelling, design and implementation of relational databases

Database modelling
• Database modelling starts with conceptual model i.e. a global view of the data.
• Usually organisation-wide view of data from perspective of senior managers (top-
down view).
• Most widely used database model is entity–relationship model.
• Entity–relationship model logically and graphically depicts relationships between
entities and attributes, and between entities and entities.
• Database modelling uses ER diagrams to develop blueprint for design.

1-28
5. Database modelling, design and implementation of relational databases

Entity–relationship models
• Entity–relationship models are depicted by entity–relationship diagrams (ER
diagrams) and provide a conceptual view that incorporates:
➢ Entities: represent real-world things or objects such as employees, types of employees,
customers, types of customers, suppliers and types of suppliers.
➢ Attributes: characteristics of entities. For example, a customer may have attributes
including first name, last name, address, telephone number and email.
➢ Relationships: associations between entities. Cardinality* among the entities describes
the relationship as 1:1 (one-to-one), 1:N (one-to-many) or M:N (many-to-many).

Note: *In data modeling, cardinality refers to the relationship of data in one database table with respect to another table.

1-29
5. Database modelling, design and implementation of relational databases

• E-R (above) depicts relationship between a salesperson and a customer


• Cardinality (relationship between entities) shows each salesperson has many customers but each customer has only one salesperson.
• Business rules (connectivity's) represent number of occurrences in the related entity.
• Each salesperson can have up to ten customers.
• Each customer must have only one salesperson.
1-30
5. Database modelling, design and implementation of relational databases

Entity Relationship Diagram (ERD) Tutorial - Part 1

Entity Relationship Diagram (ERD) Tutorial - Part 2

1-31
Weekly Question
❑ See question in Moodle.
❑ Do question in class.
❑ This is Assessment 1.

1-32
1-33

You might also like