0% found this document useful (0 votes)
2 views4 pages

Assignment (DBMS)

The document outlines an assignment for creating an ER diagram for an order and purchase process involving workers, departments, projects, buy orders, suppliers, and products. It details the entities, their attributes, and the relationships between them, such as workers belonging to departments and marking buy orders. The assignment is submitted by Maira Ashfaq to Ma’am Rabail at Nimble Institute Of Modern Studies.

Uploaded by

mairaashfaq786
Copyright
© © All Rights Reserved
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)
2 views4 pages

Assignment (DBMS)

The document outlines an assignment for creating an ER diagram for an order and purchase process involving workers, departments, projects, buy orders, suppliers, and products. It details the entities, their attributes, and the relationships between them, such as workers belonging to departments and marking buy orders. The assignment is submitted by Maira Ashfaq to Ma’am Rabail at Nimble Institute Of Modern Studies.

Uploaded by

mairaashfaq786
Copyright
© © All Rights Reserved
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
You are on page 1/ 4

DBMS

Assignment
Submitted To: Ma’am Rabail
BY
Maira Ashfaq
B.Sc (Math II)
ID: 24

NIMS
Nimble Institute Of Modern Studies
E-R Project

Prepare an ER Diagram for order and purchase process.

Project Description:

 A department has many workers. A worker belongs to a department. Attributes of department


include Dept_ID (identifier), name, and address. Attributes of worker include Worker_ID
(identifier), name and address.
 A worker participates in many projects. A project may be assigned to many workers. Attributes
of project include project_no, description.
 A worker also marks many buy_orders and buy_order is delivered by suppliers. Attributes of
buy_order include order_id (identifier), delivery date, order date. Supplier attribute include
supplier_ID (identifier), name.
 Buy_Order contains one or many products. Attributes of product include product_no
(identifier), color.

Solution:

Step 1: Identify Entities

 Worker: A worker works in a department. A department contains many workers.


 Department: There are many departments. In one department many workers can work.
 Project: Projects are assigned to workers.
 Buy_Order: Buy_Order is marked by workers which customers order.
 Supplier: Supplier is a person who supplies or delivers the products which customers order.
 Product: Products are the things that are ordered in Buy_Order.

Step 2: Identify Attributes


Attributes on Worker

 Worker_ID: A unique identifier for worker. This attribute must be unique.


 Name: The name of worker.
 Address: The address of worker where he lives.

Attributes on Department

 Dept_ID: It is a unique identifier for department.


 Name: It includes the name of department.
 Location: The place or address where department is located.
Attribute on Project

 Project_no: It is a unique identifier.


 Topic: It contains the project name or short description about project.

Attributes on Buy_Order

 Order_ID: A unique identifier for order. This attribute must be unique.


 Order_Date: The date when the order was ordered.
 Delivery_Date: It contains the date when order was delivered.

Attributes on Supplier

 Supplier_ID: A unique identifier for supplier.


 Name: The name of supplier.

Attributes on Product

 Color: The color of product.


 Product_no: The unique identifier for product.

Step 3: Identify Relationship

 Belongs: A worker belongs to one department. A department may have many workers.
 Participates: A worker participates in many projects. A project may be assigned to many
workers.
 Marks: A worker marks many buy_order. A buy_order is marked by only one worker.
 Contain: A buy_order may contain many products. A product may appear in many buy_order or
may not appear in any buy_order.
 Delivery: A buy_order is delivered by a supplier. A supplier may or may not deliver many
buy_orders.
Step 4: Draw ER diagram

Dept_ID
Name Address
Name

Worker_ID Location

WORKER Belongs DEPARTMENT

Participates
Marks

Project_no

PROJECT BUY_ORDER Contains


Topic

Order_ID Order_Date
Delivery
Delivery_Date PRODUCT

Color Product_no
SUPPLLIER

Supplier_ID Name

You might also like