DBMSL Assignment 1
DBMSL Assignment 1
CS A3
Theory Questions
An Entity Relationship Diagram (ER Diagram) pictorially explains the relationship between entities to be
stored in a database. Fundamentally, the ER Diagram is a structural design of the database. It acts as a
framework created with specialized symbols for the purpose of defining the relationship between the database
entities. ER diagram is created based on three principal components: entities, attributes, and relationships.
Significance in DBMS:
• ER Diagram helps you conceptualize the database and lets you know which fields need to be embedded
for a particular entity
• ER Diagram gives a better understanding of the information to be stored in a database
• It reduces complexity and allows database designers to build databases quickly
• It helps to describe elements using Entity-Relationship models
• It allows users to get a preview of the logical structure of the database
A given ER model can be converted into Relational model. A Relational model includes Relations, Tuples,
Attributes, Keys, and Foreign keys.
• Relation is a table made from tuples.
• A Tuple is a row of data.
• An Attribute is a characteristic of the relation.
Implementation Question- Draw an ER diagram for the following problem statements and then convert
them into database relational schema.
• Customer must orders one or more items. Each customer is identified by his/her name. The postal
address and email address of the customer are also required for the correct placement of order.
• Items have their name and price to be shown to the customers.
• Shopping carts are created by the orders of the customers.
• Shopping carts contain at least one item.
• An order must have at least one requested item.
• Not all items have customers.
• Distinct companies produce distinct items which are differentiated by the company’s name.
• Payment must be made via credit cards. The payment process has to be done after the credit card’s
verification.