Database Design for ABC Company
VerifiedAdded on 2023/03/30
|22
|1388
|435
AI Summary
This document provides an overview of the database design for ABC Company, including normalization, entity relationships, and implementation. It covers topics such as customer, supplier, product, stock, order, and payment entities, as well as use case diagrams, data dictionary, and implementation details. The document also includes sample queries, forms, and reports.
Contribute Materials
Your contribution can guide someone’s learning journey. Share your
documents today.
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/9a98419c-710b-4f23-b150-a3ed18245a28-page-1.webp)
Database design for ABC Company
Secure Best Marks with AI Grader
Need help grading? Try our AI Grader for instant feedback on your assignments.
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/32409adc-b86b-4909-bf78-d63cbd786b11-page-2.webp)
Introduction
ABC Inc. is an American multinational technology company headquartered in Cupertino, California, that
designs, develops, and sells consumer electronics, computer software, and online services. Its hardware
products include the iPhone smartphone, the iPad tablet computer, the Mac personal computer, the
iPod portable media player, the ABC Watch smartwatch, and the ABC TV digital media player. ABC's
consumer software includes the macOS and iOS operating systems, the iTunes media player, the Safari
web browser, and the iLife and iWork creativity and productivity suites. Its online services include the
iTunes Store, the iOS App Store and Mac App Store, ABC Music, and iCloud.
Business rules approaches in software development are concentrated in finding ways and facilities that
would support automatic propagation of business changes from business environment to software
systems. This would help to bridge the gap between business and technology, as aligning information
systems and business operation is one of the fundamental problems in all organizations. To reach that
goal, it has to be clear how business rules should be dealt with, as a special kind of software
requirements, in each phase of the software development lifecycle. Accordingly, at least the following
aspects have to be considered in this process: rules identification, business rules specification, rules
implementation and rules management. A business rules implementation strategy assumes identifying
both the place and the way of how to implement a business rule.
Company business rules:
Term — The focus on business, in that there's no reference to information systems or concepts of
information systems - focuses exclusively on how business people think.
Fact — People involved in the business (as "customers") communicate vocabulary and business rules to
computer professionals (as "suppliers"), in the form of system requirements specifications.
Derivation — Database design should be influenced on the meaning that business people and business
analysts give to certain objects or terms from the business vocabulary. And discussions regarding these
aspects might be endless. If we consider a very simple ecommerce application
Constraint — Constraint is a generic term related to table columns which limits data values in order to
preserve database integrity. Integrity of the relational model restrictions are structural and behavioral
ABC Inc. is an American multinational technology company headquartered in Cupertino, California, that
designs, develops, and sells consumer electronics, computer software, and online services. Its hardware
products include the iPhone smartphone, the iPad tablet computer, the Mac personal computer, the
iPod portable media player, the ABC Watch smartwatch, and the ABC TV digital media player. ABC's
consumer software includes the macOS and iOS operating systems, the iTunes media player, the Safari
web browser, and the iLife and iWork creativity and productivity suites. Its online services include the
iTunes Store, the iOS App Store and Mac App Store, ABC Music, and iCloud.
Business rules approaches in software development are concentrated in finding ways and facilities that
would support automatic propagation of business changes from business environment to software
systems. This would help to bridge the gap between business and technology, as aligning information
systems and business operation is one of the fundamental problems in all organizations. To reach that
goal, it has to be clear how business rules should be dealt with, as a special kind of software
requirements, in each phase of the software development lifecycle. Accordingly, at least the following
aspects have to be considered in this process: rules identification, business rules specification, rules
implementation and rules management. A business rules implementation strategy assumes identifying
both the place and the way of how to implement a business rule.
Company business rules:
Term — The focus on business, in that there's no reference to information systems or concepts of
information systems - focuses exclusively on how business people think.
Fact — People involved in the business (as "customers") communicate vocabulary and business rules to
computer professionals (as "suppliers"), in the form of system requirements specifications.
Derivation — Database design should be influenced on the meaning that business people and business
analysts give to certain objects or terms from the business vocabulary. And discussions regarding these
aspects might be endless. If we consider a very simple ecommerce application
Constraint — Constraint is a generic term related to table columns which limits data values in order to
preserve database integrity. Integrity of the relational model restrictions are structural and behavioral
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/ef6ead5e-2031-42b6-94df-ab964c227ee7-page-3.webp)
Database Design
Entity Name:
Customer, Supplier, Product, Stock, Order, Payment
Normalization:
Database Normalization is a technique of organizing the data in the database. Normalization is a
systematic approach of decomposing tables to eliminate data redundancy and undesirable
characteristics like Insertion, Update and Deletion Anomalies. It is a multi-step process that puts data
into tabular form by removing duplicated data from the relation tables.
Normalization is used for mainly two purposes,
Eliminating redundant (useless) data.
Ensuring data dependencies make sense i.e data is logically stored.
Normalization rule are divided into following normal form.
First Normal Form
Second Normal Form
Third Normal Form
BCNF
First normal form (1NF)
As per the rule of first normal form, an attribute (column) of a table cannot hold multiple values. It
should hold only atomic values.
ABCdata (CustLastName, CustFirstName, CustAddress,CustState, CustZip, Custemail, CustPhone,
SuppLastName, SuppFirstName, SuppAddress, SuppState, SuppZip, Suppemail, SuppPhone, ProdName,
UnitPrice, ExpireDate, ProdType, Description, StockDate, Description, ProdID, Quantity, ReorderLevel,
OrderDate, Description, ProdID, Quantity, TotalPrice, Description, Paymentdate, Amount, Due,
Paymenttype, Note)
Entity Name:
Customer, Supplier, Product, Stock, Order, Payment
Normalization:
Database Normalization is a technique of organizing the data in the database. Normalization is a
systematic approach of decomposing tables to eliminate data redundancy and undesirable
characteristics like Insertion, Update and Deletion Anomalies. It is a multi-step process that puts data
into tabular form by removing duplicated data from the relation tables.
Normalization is used for mainly two purposes,
Eliminating redundant (useless) data.
Ensuring data dependencies make sense i.e data is logically stored.
Normalization rule are divided into following normal form.
First Normal Form
Second Normal Form
Third Normal Form
BCNF
First normal form (1NF)
As per the rule of first normal form, an attribute (column) of a table cannot hold multiple values. It
should hold only atomic values.
ABCdata (CustLastName, CustFirstName, CustAddress,CustState, CustZip, Custemail, CustPhone,
SuppLastName, SuppFirstName, SuppAddress, SuppState, SuppZip, Suppemail, SuppPhone, ProdName,
UnitPrice, ExpireDate, ProdType, Description, StockDate, Description, ProdID, Quantity, ReorderLevel,
OrderDate, Description, ProdID, Quantity, TotalPrice, Description, Paymentdate, Amount, Due,
Paymenttype, Note)
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/17ba1d14-f5ac-4fa5-a175-f214d6b86a26-page-4.webp)
Second normal form (2NF)
A table is said to be in 2NF if both the following conditions hold:
Table is in 1NF (First normal form)
No non-prime attribute is dependent on the proper subset of any candidate key of table.
Customer (CustID, CustLastName, CustFirstName, CustAddress,CustState, CustZip,Custemail,CustPhone,
SuppLastName, SuppFirstName, SuppAddress, SuppState, SuppZip, Suppemail, SuppPhone)
Product (ProdID, ProdName, UnitPrice, ExpireDate, ProdType, Description, StockDate, Description,
ProdID, Quantity, ReorderLevel)
Order (OrderID, OrderDate, Description, ProdID, Quantity, TotalPrice, Description, Paymentdate,
Amount, Due, Paymenttype, Note)
Third Normal form (3NF)
A table design is said to be in 3NF if both the following conditions hold:
Table must be in 2NF
Transitive functional dependency of non-prime attribute on any super key should be removed.
An attribute that is not part of any candidate key is known as non-prime attribute.
In other words 3NF can be explained like this: A table is in 3NF if it is in 2NF and for each functional
dependency X-> Y at least one of the following conditions hold:
X is a super key of table
Y is a prime attribute of table
Customer (CustID, CustLastName, CustFirstName, CustAddress,CustState, CustZip,Custemail,CustPhone)
Employee (EmpID, EmpLastName, EmpFirstName, EmpAddress, EmpState, EmpZip, Empemail,
EmpPhone)
Supplier (SuppID, SuppLastName, SuppFirstName, SuppAddress, SuppState, SuppZip, Suppemail,
SuppPhone)
Product (ProdID, ProdName, UnitPrice, ExpireDate, ProdType, Description, Stock, SuppID)
Stock (StockID, StockDate, Description, ProdID, Quantity, ReorderLevel)
Order (OrderID, OrderDate, Description, ProdID, Quantity, TotalPrice, CustID)
Payment (PaymentID, Description, Paymentdate, Amount, Due, Paymenttype, Note)
A table is said to be in 2NF if both the following conditions hold:
Table is in 1NF (First normal form)
No non-prime attribute is dependent on the proper subset of any candidate key of table.
Customer (CustID, CustLastName, CustFirstName, CustAddress,CustState, CustZip,Custemail,CustPhone,
SuppLastName, SuppFirstName, SuppAddress, SuppState, SuppZip, Suppemail, SuppPhone)
Product (ProdID, ProdName, UnitPrice, ExpireDate, ProdType, Description, StockDate, Description,
ProdID, Quantity, ReorderLevel)
Order (OrderID, OrderDate, Description, ProdID, Quantity, TotalPrice, Description, Paymentdate,
Amount, Due, Paymenttype, Note)
Third Normal form (3NF)
A table design is said to be in 3NF if both the following conditions hold:
Table must be in 2NF
Transitive functional dependency of non-prime attribute on any super key should be removed.
An attribute that is not part of any candidate key is known as non-prime attribute.
In other words 3NF can be explained like this: A table is in 3NF if it is in 2NF and for each functional
dependency X-> Y at least one of the following conditions hold:
X is a super key of table
Y is a prime attribute of table
Customer (CustID, CustLastName, CustFirstName, CustAddress,CustState, CustZip,Custemail,CustPhone)
Employee (EmpID, EmpLastName, EmpFirstName, EmpAddress, EmpState, EmpZip, Empemail,
EmpPhone)
Supplier (SuppID, SuppLastName, SuppFirstName, SuppAddress, SuppState, SuppZip, Suppemail,
SuppPhone)
Product (ProdID, ProdName, UnitPrice, ExpireDate, ProdType, Description, Stock, SuppID)
Stock (StockID, StockDate, Description, ProdID, Quantity, ReorderLevel)
Order (OrderID, OrderDate, Description, ProdID, Quantity, TotalPrice, CustID)
Payment (PaymentID, Description, Paymentdate, Amount, Due, Paymenttype, Note)
Secure Best Marks with AI Grader
Need help grading? Try our AI Grader for instant feedback on your assignments.
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/bf8a25f1-ca74-487f-a880-fde24db93b3e-page-5.webp)
Use Case Diagram
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/ad0787e0-b256-403b-bde6-47f5e7628a52-page-6.webp)
Data dictionary
Table Name : Customer
Field Name Data Type Size Primary Key Or
Foreign key
Comments
CustID Number 10 Primary Key
CustLastName Varchar2 100
CustFirstName Varchar2 100
CustAddress Varchar2 150
CustState Varchar2 30
CustZip Varchar2 30
Custemail Varchar2 30
CustPhone Varchar2 30
Table Name : Customer
Field Name Data Type Size Primary Key Or
Foreign key
Comments
EmpID Number 10 Primary Key
EmpLastName Varchar2 100
EmpFirstName Varchar2 100
EmpAddress Varchar2 150
EmpState Varchar2 30
EmpZip Varchar2 30
Empemail Varchar2 30
EmpPhone Varchar2 30
Table Name : Product
Field Name Data Type Size Primary Key Or
Foreign key
Comments
ProdID Number 10 Primary Key
ProdName Varchar2 100
UnitPrice Number 12,2
ExpireDate Date
ProdType Varchar2 2
Description Varchar2 150
Stock Number 10
SuppID Number 10 Foreign key
Table Name : Customer
Field Name Data Type Size Primary Key Or
Foreign key
Comments
CustID Number 10 Primary Key
CustLastName Varchar2 100
CustFirstName Varchar2 100
CustAddress Varchar2 150
CustState Varchar2 30
CustZip Varchar2 30
Custemail Varchar2 30
CustPhone Varchar2 30
Table Name : Customer
Field Name Data Type Size Primary Key Or
Foreign key
Comments
EmpID Number 10 Primary Key
EmpLastName Varchar2 100
EmpFirstName Varchar2 100
EmpAddress Varchar2 150
EmpState Varchar2 30
EmpZip Varchar2 30
Empemail Varchar2 30
EmpPhone Varchar2 30
Table Name : Product
Field Name Data Type Size Primary Key Or
Foreign key
Comments
ProdID Number 10 Primary Key
ProdName Varchar2 100
UnitPrice Number 12,2
ExpireDate Date
ProdType Varchar2 2
Description Varchar2 150
Stock Number 10
SuppID Number 10 Foreign key
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/9b387edd-df48-42ce-8b41-6cb795343b3b-page-7.webp)
Table Name : Supplier
Field Name Data Type Size Primary Key Or
Foreign key
Comments
SuppID Number 10 Primary Key
SuppLastName Varchar2 100
SuppFirstName Varchar2 100
SuppAddress Varchar2 150
SuppState Varchar2 30
SuppZip Varchar2 30
Suppemail Varchar2 30
SuppPhone Varchar2 30
Table Name : Order
Field Name Data Type Size Primary Key Or
Foreign key
Comments
OrderID Number 10 Primary Key
OrderDate Date
Description Varchar2 150
ProdID Number 10 Foreign key
Quantity Number 10
TotalPrice Number 12,2
CustID Number 10 Foreign key
Table Name : Stock
Field Name Data Type Size Primary Key Or
Foreign key
Comments
StockID Number 10 Primary Key
StockDate Date
Description Varchar2 150
ProdID Number 10 Foreign key
Quantity Number 10
ReorderLevel Number 10
Table Name : Payment
Field Name Data Type Size Primary Key Or
Foreign key
Comments
PaymentID Number 10 Primary Key
Description Varchar2 150
Paymentdate Date
Amount Number 10
Due Number 10
Paymentatype Varchar2 30
Note Varchar2 200
OrderID Number 10
Entity Relationship Diagram
Field Name Data Type Size Primary Key Or
Foreign key
Comments
SuppID Number 10 Primary Key
SuppLastName Varchar2 100
SuppFirstName Varchar2 100
SuppAddress Varchar2 150
SuppState Varchar2 30
SuppZip Varchar2 30
Suppemail Varchar2 30
SuppPhone Varchar2 30
Table Name : Order
Field Name Data Type Size Primary Key Or
Foreign key
Comments
OrderID Number 10 Primary Key
OrderDate Date
Description Varchar2 150
ProdID Number 10 Foreign key
Quantity Number 10
TotalPrice Number 12,2
CustID Number 10 Foreign key
Table Name : Stock
Field Name Data Type Size Primary Key Or
Foreign key
Comments
StockID Number 10 Primary Key
StockDate Date
Description Varchar2 150
ProdID Number 10 Foreign key
Quantity Number 10
ReorderLevel Number 10
Table Name : Payment
Field Name Data Type Size Primary Key Or
Foreign key
Comments
PaymentID Number 10 Primary Key
Description Varchar2 150
Paymentdate Date
Amount Number 10
Due Number 10
Paymentatype Varchar2 30
Note Varchar2 200
OrderID Number 10
Entity Relationship Diagram
Paraphrase This Document
Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/f67004f0-cd23-4347-b836-6d989b296b8e-page-8.webp)
Implementation
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/913ce097-b313-42fd-bafc-c563770e32bc-page-9.webp)
Table creation
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/bde16b80-90ff-4426-aaab-6f2a2cf0faa9-page-10.webp)
Secure Best Marks with AI Grader
Need help grading? Try our AI Grader for instant feedback on your assignments.
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/727f6090-259d-4cb9-87ee-d82895287650-page-11.webp)
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/53d71172-9979-4bde-bb9a-c301d7d5d5ed-page-12.webp)
Insert Data
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/065c2bad-c7a5-4298-80bc-ffe290eae479-page-13.webp)
Paraphrase This Document
Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/f3309ee5-2529-4669-a244-b598e3d93f4a-page-14.webp)
Constraints:
Primary Key
CustID
EmpID
SuppID
ProdID
StockID
OrderID
PaymentID
Foreign Key
Product (SuppID)
Stock (ProdID)
Order (ProdID)
Order (CustID)
Assumptions
Make sure to include an overview of all the requirements to start your business
Outline all of your products, your inventory and packaging
Understanding of the current market and your competition
Customer service and customer acquisition
Consider all the development requirements
Budget planning, break-even analysis, projected profit and loss
Products and services offered by your business
Primary Key
CustID
EmpID
SuppID
ProdID
StockID
OrderID
PaymentID
Foreign Key
Product (SuppID)
Stock (ProdID)
Order (ProdID)
Order (CustID)
Assumptions
Make sure to include an overview of all the requirements to start your business
Outline all of your products, your inventory and packaging
Understanding of the current market and your competition
Customer service and customer acquisition
Consider all the development requirements
Budget planning, break-even analysis, projected profit and loss
Products and services offered by your business
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/bb1a8724-6e29-4491-88d7-c35983418f2d-page-15.webp)
Forms
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/d8062356-041b-4042-8b00-d96ea89bd9c4-page-16.webp)
Secure Best Marks with AI Grader
Need help grading? Try our AI Grader for instant feedback on your assignments.
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/9eac761b-a43d-4480-a8e9-a774a21d0182-page-17.webp)
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/8a182c08-c073-486d-a5aa-9cba62d4b1e6-page-18.webp)
Reports
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/00cfa0f1-c6dc-4efc-b15f-48ca2723806e-page-19.webp)
Paraphrase This Document
Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/38061acc-c276-4e4e-b40b-491d7fa5112e-page-20.webp)
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/96877865-f927-43c8-a65e-7fe814a8cdca-page-21.webp)
Queries
SELECT Customer.CustLastName, Customer.CustAddress, Customer.CustPhone
FROM Customer;
SELECT Payment.Paymentdate, Avg(Payment.Amount) AS AvgOfAmount, Payment.Paymentatype
FROM Payment
GROUP BY Payment.Paymentdate, Payment.Paymentatype;
SELECT Product.ProdName, Product.UnitPrice, Stock.Quantity, Stock.ProdID
FROM Product INNER JOIN Stock ON Product.ProdID = Stock.ProdID
WHERE (((Stock.ProdID)=1 Or (Stock.ProdID)=2));
SELECT Stock.ProdID, Stock.StockDate, Sum(Stock.Quantity) AS SumOfQuantity
FROM Stock
GROUP BY Stock.ProdID, Stock.StockDate, Stock.ProdID;
SELECT Supplier.SuppLastName, Supplier.SuppPhone, Product.ProdName, Product.ProdType,
Stock.Quantity
FROM (Supplier INNER JOIN Product ON Supplier.SuppID = Product.SuppID) INNER JOIN Stock ON
Product.ProdID = Stock.ProdID;
SELECT Customer.CustLastName, Customer.CustAddress, Customer.CustPhone
FROM Customer;
SELECT Payment.Paymentdate, Avg(Payment.Amount) AS AvgOfAmount, Payment.Paymentatype
FROM Payment
GROUP BY Payment.Paymentdate, Payment.Paymentatype;
SELECT Product.ProdName, Product.UnitPrice, Stock.Quantity, Stock.ProdID
FROM Product INNER JOIN Stock ON Product.ProdID = Stock.ProdID
WHERE (((Stock.ProdID)=1 Or (Stock.ProdID)=2));
SELECT Stock.ProdID, Stock.StockDate, Sum(Stock.Quantity) AS SumOfQuantity
FROM Stock
GROUP BY Stock.ProdID, Stock.StockDate, Stock.ProdID;
SELECT Supplier.SuppLastName, Supplier.SuppPhone, Product.ProdName, Product.ProdType,
Stock.Quantity
FROM (Supplier INNER JOIN Product ON Supplier.SuppID = Product.SuppID) INNER JOIN Stock ON
Product.ProdID = Stock.ProdID;
![Document Page](https://desklib.com/media/document/docfile/pages/unit-17-database-design-concepts-jtsd/2024/09/12/037f0c41-2e4d-40f6-8814-b1cfb45b4f0e-page-22.webp)
Conclusion
As should be clear from this paper, modern commercial database systems are grounded both in
academic research and in the experiences of developing industrial-strength products for high-end
customers. The task of writing and maintaining a high-performance, fully functional relational DBMS
from scratch is an enormous investment in time and energy. Many of the lessons of relational DBMSs,
however, translate over to new domains. Web services, network-attached storage, text and e-mail
repositories, notification services, and network monitors can all benefit from DBMS research and
experience. Data-intensive services are at the core of computing today, and knowledge of database
system design is a skill that is broadly applicable, both inside and outside the halls of the main database
shops. These new directions raise a number of research problems in database management as well, and
point the way to new interactions between the database community and other areas of computing.
As should be clear from this paper, modern commercial database systems are grounded both in
academic research and in the experiences of developing industrial-strength products for high-end
customers. The task of writing and maintaining a high-performance, fully functional relational DBMS
from scratch is an enormous investment in time and energy. Many of the lessons of relational DBMSs,
however, translate over to new domains. Web services, network-attached storage, text and e-mail
repositories, notification services, and network monitors can all benefit from DBMS research and
experience. Data-intensive services are at the core of computing today, and knowledge of database
system design is a skill that is broadly applicable, both inside and outside the halls of the main database
shops. These new directions raise a number of research problems in database management as well, and
point the way to new interactions between the database community and other areas of computing.
1 out of 22
Related Documents
![[object Object]](/_next/image/?url=%2F_next%2Fstatic%2Fmedia%2Flogo.6d15ce61.png&w=640&q=75)
Your All-in-One AI-Powered Toolkit for Academic Success.
+13062052269
info@desklib.com
Available 24*7 on WhatsApp / Email
Unlock your academic potential
© 2024 | Zucol Services PVT LTD | All rights reserved.