Cardinality Relationships
Cardinality can be
• One-to-one (1:1)
• One-to-many (1:*),
• many-to-one (*:1), or
• Many-to-many (*:*)
Cardinalities provide useful information
about
• the nature of the company being modeled and
• the business policies that it follows.
ONE-TO-ONE (1:1)
ONE-TO-MANY (1:*)
MANY-TO-ONE (*:1),
MANY-TO-MANY (*:*)
Creating Records and
Database Relationships
Creating records
• individual records for the data fields
Database relationships
• link tables together
• enable users to create multitable reports
To create database relationships
• launch the relationships window,
• select tables, and
• link the tables.
Chapter 13
Organizing and Manipulating the Data in Databases
Introduction
Normalization
Validating the Data in Databases
Extracting Data From Databases: Data Manipulation Languages
(DMLs)
Object-Oriented Databases, Multimedia Databases, and Data
Warehouses
Normalization
Flat files are files with no sequence or
order to them, except perhaps
chronological.
Flat files make it almost impossible to
find a particular record easily or use
file data productively.
Normalization is a process of examining
and arranging file data in a way that
enables designers to avoid problems
when files are used or modified later.
First Normal Form
A database is in first normal form (1 NF) if all the
record’s attributes (data fields) are well defined
and the information can thus be stored in a flat
file.
Problems:
data redundancy
insertion anomaly
deletion anomaly
Second Normal Form
A database is in second normal form (2 NF) if it is
in 1 NF and all the data items in each record
depend on the record’s primary record key.
This approach results in a more efficient design
and eliminates much of the first file’s data
redundancy.
Third Normal Form
Our goal is to create a database that is minimally
in third normal form (3 NF).
A database is in third normal form if it is in second
normal form and contains no transitive
dependencies - i.e., no relationships in which data
field A determines data field B.
Database Management
Systems
A database management system (DBMS) is
a separate software system that enable
users to create, delete, access, query, view,
analysis, or reorganize modify, and utilize
database information more efficiently.
The data definition language (DDL) of a
DBMS enables its users to define the record
structure of any particular database table.
The data manipulation language (DML)
enables users to perform tasks such as
querying, changing records, and deleting
records.
User Views Schemas and Subschemas
The database schema is a map or plan of the entire database.
Any particular user or application program will be interested in
only a subset of the schema, called the subschema.
A database schema must be flexible enough to satisfy the
subschema uses required of it.
Data Manipulation Languages
Many relational databases support structured query
language (SQL).
Hypertext can also be used for finding information in a
database.
End-user programming allows users to perform their
own data processing without technical
assistance from IT professionals.
Online Analytical
Processing
Complex multidimensional data analysis performed
on database information is called online analytical
processing (OLAP).
OLAP packages allow end users to perform their own
database analysis, including data mining.
Object-Oriented and
Multimedia Databases
The object-oriented database (OODB) contains
both the text data of traditional databases and
information about the set of actions that can be
taken on these data fields.
Many OODBs are multimedia databases that
include graphics, audio information,
and animation.
Characteristics of a
Data Warehouse
A data warehouse pools data from separate
applications into a large common body of information.
Characteristics of data warehouses:
1. Data are free of errors.
2. Defined uniformly.
3. Span a longer time horizon than the company’s transaction
systems.
4. Optimized data relationships that allow user to answer
complex questions.
Advantages of Data Warehouse
Make organizational information
available on a corporate-wide basis,
which is central to the concept of
enterprise-wide databases.
Facilitates data mining and enables users
to identify target markets or its most
desirable customers.
Chapter 14
Creating Database Forms and Reports
• Introduction
• Forms
• Reports
Form
• A Form is a custom-designed screen for
entering new records into, or displaying
existing records from a database table.
Structure of a Form
1. Heading section at the top.
2. Detail section, usually the largest section,
displays record information.
3. Navigation bar at the bottom.
Subforms
• A Subform is a form within a form
• A display of data that is related to the
information in the main form.
Reports
1. Database reports provide custom information
to database users.
2. Reports can be simple documents or highly
complex outputs that combine information
from several tables.
3. Reports are strictly outputs and do not allow
users to input data.
A Typical Report Has
1. report heading,
2. page heading,
3. group heading,
4. detail or body,
5. group footer,
6. page footer, and
7. report footer.