You are on page 1of 11

Entity relationship diagram

case

Amina naseer
mscits10a31
Case 1
• A painter can paint many paintings ; each
painting is paint by one painter .A gallery can
have many paintings . A painting can be
exhibited by a gallery .Many common people
visit the gallery . But it is not compulsory that
a gallery can be visited by common people
Representation of entity

A painter can paint many paintings ; each


painting is paint by one painter .A gallery
can have many paintings . A painting can
be exhibited by a gallery .Many common
people visit the gallery . But it is not
compulsory that a gallery can be visited
by common people
Entity representation

Painter Painting

Common people Gallery


Find Relationships

Painter Painting Gallery Common


people
Painter paints
Painting Paints by exhibit
Gallery exhibit Visit by
Common visit
people
Drawing Rough ERD

Painter paint Painting

display

Common people visit Gallery


Cardinality Notation
ERD with cardinality

Painter paint Painting

display

Common people visit Gallery


Rough ERD Plus Primary Keys
• \\
Painter name

Painter paint Painting

Painter ID Painting no

display
People name
Gallery no

Common people visit Gallery

People ID
Gallery name
Map Attributes

Attribute Entity Attribute entity


Painter ID Painter Gallery no Gallery
Painter name Painter Gallery name Gallery
People ID Common people Painting no Painting
Name Common people
Draw Fully Attributed ERD
• \\
Painter name

Painter paint Painting

Painter ID Painting no

display
People name
Gallery name Gallery no

Common people visit Gallery

People ID invited

Guest name
Special guest

You might also like