0% found this document useful (0 votes)
8 views21 pages

Database Design and Normalization Guide

The document outlines the process of database design, including requirement formulation, conceptual design through E-R modeling and normalization, and physical design and implementation. It explains the importance of understanding user views, entities, relationships, and the steps involved in normalization to refine the database structure. Additionally, it highlights features of Oracle 9i that enhance database performance, management, security, and application areas such as internet content management and ecommerce integration.

Uploaded by

arjun2u
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views21 pages

Database Design and Normalization Guide

The document outlines the process of database design, including requirement formulation, conceptual design through E-R modeling and normalization, and physical design and implementation. It explains the importance of understanding user views, entities, relationships, and the steps involved in normalization to refine the database structure. Additionally, it highlights features of Oracle 9i that enhance database performance, management, security, and application areas such as internet content management and ecommerce integration.

Uploaded by

arjun2u
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Database Design

Seema Sirpal
Delhi University Computer Centre
Database Design

 Requirement Formulation and Analysis


- Collection and Documentation of Requirement
- Analysis of Requirement
 Conceptual Design
- Data Modeling
First Level – E-R Modeling
Second Level - Normalization
 Physical Design & Implementation
Requirement Analysis

The Objective is to answer the following questions:

• What are user-views of the data (present & future)?


• What data elements (or attributes) are required in these
user-views?
• What are entities and their primary keys?
• What are the operational requirements reg. Security, Integrity
etc.?
Conceptual Design

The relationship between the collection of data in a system may


be graphically represented using data modeling. It provides a
Simplified approach to the structured design of the complex
system .

Data Modeling is achieved in two levels:


• ER Modeling
• Normalization
ER Diagram

Entity Relationship Diagrams (ERDs) illustrate the logical


structure of databases. It uses three basic concepts

• Entities
• Their Attributes
• The Relationships that exist between the entities
ER Diagram

Graphical notations for ER Diagram :

Entity
An entity is an object or concept about which you want to store
information.

Attributes
Attributes are the properties or characteristics of an entity.

Key attribute
A key attribute is the unique, distinguishing characteristic of the entity. For
example, an employee's social security number might be the employee's
key attribute.
ER Diagram

Graphical notations for ER


Diagram :
Relationships
Relationships illustrate how two entities share information in the database
structure.

Cardinality
Cardinality specifies how many instances of an entity relate to
one instance of another entity.
ER Diagram
ER Diagram

Example

An Organization has employees assigned to specific


departments. The employees may work on several projects at
the same time.

The project uses parts which are supplied by different


suppliers, and stored in various warehouses.
ER Diagram Process

• Identify the entities that your database must represent

• Determine the cardinality relationships among the entities and


classify them as one of
o One-to-one
o One-to-many
o Many-to-many

• Draw the entity-relationship diagram

• Determine the attributes of each entity

• Define the (unique) primary key of each entity


From E-R Model to Database Design

• Entities with one-to-one relationships should be merged into a single entity

• Each remaining entity is modeled by a table with a primary key and


attributes, some of which may be foreign keys

• One-to-many relationships are modeled by a foreign key attribute in the


table representing entity on the "many" side of the relationship

• Many-to-many relationships among two entities are modeled by a third


table that has foreign keys that refer to the entities. These foreign keys
should be included in the relationship table's primary key, if appropriate

• Commercially available tools can automate the process of converting a E-R


model to a database schema
Normalization

• Refinement of E-R Model


• Improves database design
• Ensures minimum redundancy of data

An Un-normalized Data Structure contains redundant and


disorganized data which need to be organized, by dividing the
data over several tables to avoid redundancy. This is achieved
by going through the process of Normalization.
Normalization
Example
• Invoice No.
• Invoice Date
• Order No.
• Challan No.
• Customer No.
• Customer Name
• Item No.
• Item Desc.
• Qty Sold
• Rate
• Discount
• Invoice Value

This table presents several difficulties in Insertion, Updation, Deletion of


Fields.
Normalization
Steps in Normalization
First Normal Form

• Identify repeating groups of fields


• Remove repeating groups to a separate table
• Identify the keys for the table
• Key of parent table is brought as part of the concatenated key
of the second table

A Table is in 1NF when it contains no repeating groups.


Normalization
First Normal Form

• Invoice Table
- Invoice No.
- Invoice Date
- Order No.
- Challan No.
- Cust. No.
- Cust Name
- Invoice Value
• Invoice Items
- Invoice No,
- Item No.
- Item description
- Qty Sold
- Rate
- Discount
Normalization
Second Normal Form

• Check if all fields are dependent on the whole key


• Remove fields that depend on part of the key
• Group partially-dependent fields as a separate table
• Name the tables
• Identify key(s) to the table(s)

A Table is in 2NF if all its non-key fields are fully dependent on


the whole key.
Normalization
Second Normal Form

• Invoice Table

• Invoice Items
- Invoice No.
- Item No.
- Qty sold
- Discount

• Item Table
- Item No.
- Item description
- Rate
Normalization
Third Normal Form

• Remove fields that depend on other non-key fields

• Remove fields that can be calculated or derived from logic.

• Group interdependent fields as separate tables.

A Table is in 3NF if all the non-key fields of the table are


independent of all other non-key fields of the same table.
Normalization
Third Normal Form
• Invoice Table
- Invoice No.
- Invoice Date
- Order No.
- Challan No.
- Cust. No.
- Invoice Value
• Customer Table
- Cust No.
- Cust name
• Invoice Items
- Invoice No.
- Item No.
- Qty sold
- Discount
• Item Table
- Item No.
- Item description
- Rate
Features of Oracle9i

An overview of the changes that have been made to Oracle 9i to improve


the following technical aspects :-

• database performance
• ease of management
• scalability
• security
• availability

Application areas:

• Internet content management


• ecommerce integration
• packaged applications
• Business Intelligence
Features of Oracle9i
INTERNET CONTENT MANAGEMENT
Oracle 9i can be used for the storage and manipulation of many different types of data. The new
features are:-

- Internet File Store improvements


- searching/indexing of multimedia and XML data
- support for collaborative projects via the creation of shared workspaces, allowing multiple
versions of content to exists simultaneously
- ability to create applications to make use of location information of clients and services (e.g. for
use with mobile phones)

ECOMMERCE INTEGRATION
The enhancements Oracle 9i provides in this area are:

- pre-built objects for creating store fronts, exchanges and portals to provide a faster time-to-
market and enable easier integration with the back-end
- support for standard messaging formats to enable faster integration of the store front with the
back-end and external systems

Common questions

Powered by AI

Commercially available tools can automate the conversion of an ER model to a database schema by providing functionalities like automatic generation of SQL scripts that define tables, relationships, and constraints as per the ER model . These tools can map entities to tables, relationships to foreign keys, and attributes to columns automatically. The benefits of this automation include reduced human error, increased efficiency, and quicker deployment times, as it simplifies complex design processes and ensures a higher degree of consistency and accuracy in table structure and data management .

Normalization is crucial in database design as it refines the E-R model by organizing data to reduce redundancy and improve data integrity. It enhances database functionality by ensuring minimal redundancy, thus reducing the risk of anomalies during data operations such as insertions, updates, and deletions . The process involves applying rules, such as the First, Second, and Third Normal Forms, which help structure databases by eliminating repeating groups, ensuring full dependency of non-key fields on primary keys, and removing transitive dependencies . This organized structure leads to a more efficient and stable database system.

Operational requirements regarding security and integrity are crucial in database design to protect data from unauthorized access and to ensure its correctness and consistency . Security requirements can be addressed through authentication, authorization, and encryption measures that control and monitor access to data resources . Integrity requirements are handled by implementing constraints such as primary keys, foreign keys, and validation rules that maintain consistent and accurate data throughout its lifecycle within the database . Additionally, database management systems (DBMS) can use transaction controls and recovery systems to ensure data integrity in concurrent use and failure scenarios.

The First Normal Form (1NF) requires that tables have no repeating groups, meaning each table should have only atomic values and a unique identifier or key . The Second Normal Form (2NF) requires that all non-key fields are fully functionally dependent on the whole primary key; this involves removing partial dependencies and separating them into different tables if necessary . Third Normal Form (3NF) further refines the structure by ensuring that all non-key fields are independent of any other non-key fields, eliminating transitive dependencies by creating separate tables for these interdependent fields . These steps collectively aim to minimize redundancy and dependence, thus leading to a more efficient database structure.

Primary keys play a critical role in ensuring data integrity by uniquely identifying each entity instance in a database table during the conceptual design phase . In ER modeling, primary keys are determined by selecting attributes that have unique values for each instance of an entity, providing a reliable way to access each record . The determination process involves identifying key attributes that are essential for the integrity and unique identification of records over the entire database system. These keys are foundational in defining relationships between entities and are incorporated into relational database tables.

An un-normalized data structure is often plagued with redundancy, inconsistency, and anomaly problems, such as difficulty in insertion, updating, or deletion operations due to data duplication . These challenges arise because the same information is stored multiple times, leading to increased storage requirements and potential for data anomalies . Normalization addresses these challenges by structuring data into tables that reduce redundancy, ensure data consistency, and support efficient and accurate data manipulation. Through the application of normalization rules, data is organized into well-defined tables with minimal redundancy .

Oracle 9i introduces new features for ecommerce integration such as pre-built objects for creating store fronts, exchanges, and portals, which provide a faster time-to-market and simplify integration with back-end systems . It supports standard messaging formats, facilitating quicker and more seamless integration with external systems, which is crucial for efficient e-commerce operations. These features help businesses by enabling rapid deployment of ecommerce solutions, reducing development efforts, and enhancing operational efficiency in handling ecommerce transactions .

In ER diagrams, relationships and cardinality significantly influence the design of database tables by determining how entities are connected and interact. Cardinality defines the nature of relationships in terms of number (one-to-one, one-to-many, many-to-many), which directly affects how tables are structured . One-to-many relationships are typically represented with foreign keys referencing the primary key of the 'one' side's table, whereas many-to-many relationships necessitate the creation of a junction table to manage these complex associations . Thus, understanding these concepts helps design table structures that correctly represent data interactions in the database.

ER diagrams play a pivotal role in the conceptual design phase of databases by graphically illustrating the logical structure of the database. They provide a simplified approach to design complex systems by visually representing entities, their attributes, and the relationships between entities . This visualization helps in understanding how data elements are related and in structuring a database that faithfully represents user requirements and the data environment .

Oracle 9i enhances business intelligence by integrating features that improve database performance, management, scalability, and security, which are crucial for robust data analytics and decision-making . For internet content management, Oracle 9i offers improvements like better storage and manipulation of multimedia and XML data, the creation of shared workspaces for collaborative projects, and the ability to develop location-based applications . These features facilitate more efficient management and delivery of internet content and support complex data handling and collaboration requirements.

You might also like