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

CS 1103-01 - AY2024-T3 Learning Journal Unit 2

Student Name: John Paul Balmaceda Student Number: C2047957

Customer Management:

The system must track customers.

Each customer has a unique identifier (CustomerID).

The system stores the customer's last name, first name, address, phone number, and

email.

Sales Tracking:

Sales transactions need to be recorded.

Each sale has a unique identifier (SaleID).

The system records the date of the sale (SaleDate), the subtotal, the tax amount, and

the total amount of the sale.

Sale Item Details:

Each sale consists of one or more items.

Each item in a sale (Sale Item) has a unique identifier within that sale (SaleItemID).

The system tracks the price of each item at the time of sale (ItemPrice).
Inventory Management:

Items available for sale are tracked.

Each item has a unique identifier (ItemID).

The system stores a description and cost of each item.

Store Information:

The sales take place at specific stores.

Each store is uniquely identified (StoreID).

The system records the store's name, phone number, and email.

Relationships:

A sale is made to a customer by a store.

A customer can make many purchases (sales), and a sale is made to one customer.

A store can make many sales, and a sale is made by one store.

A sale can consist of many sale items, but a sale item belongs to one sale.

An item can be sold many times in different sales, and a sale item corresponds to one

item.
Now let's describe the cardinalities in the diagram:

Customer to Sale (Buys/SoldTo): A customer can have multiple sales (1 to many), but

each sale is associated with one and only one customer (many to 1).

Sale to Store (Sells/SoldBy): A store can have multiple sales (1 to many), but each sale

is conducted by one and only one store (many to 1).

Sale to Sale Item: Each sale can have multiple sale items (1 to many), but each sale

item is part of one and only one sale (many to 1).

Item to Sale Item: An item can be part of multiple sale items (1 to many), indicating it

can be sold multiple times in different sales. Each sale item corresponds to one and

only one item (many to 1).

Reference:

Sharma, N., Perniu, L., Chong, R. F., Iyer, A., Nandan, C., Mitea, A. C., Nonvinkere, M. &

Danubianu, M. (2010). Database fundamentals. IBM Canada.

You might also like