Symbols in Crow's Foot Notation: Attributes

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 7

Symbols in Crow’s Foot Notation

Let’s now take a look at the representation of entities and relationships in


crow’s foot notation.

Entities
Definition
An entity is a representation of a class of object. It can be a person, place,
thing, etc. Entities usually have attributes that describe them.

In crow’s foot notation, an entity is represented by a rectangle, with its name


on the top. The name is singular (entity) rather than plural (entities).

Attributes

Definition
An attribute is a property that describes a particular entity.
The attribute(s) that uniquely distinguishes an instance of the entity is
the identifier. Usually, this type of attribute is marked with an asterisk.
Relationships
Definition
Relationships illustrate the association between two entities. They are
presented as a straight line. Usually, each relationship has a name, expressed
as a verb, written on the relationship line. This describes what kind of
relationship connects the objects.

Note that the mentioned type of relationship is binary. In the Entity-


Relationship model, representing a ternary or higher order of relationship is
problematic.

Cardinality
Relationships have two indicators. These are shown on both sides of the line.

 The first one (often called multiplicity) refers to the maximum number of


times that an instance of one entity can be associated with instances in
the related entity. It can be one or many.
 The second describes the minimum number of times one instance can
be related to others. It can be zero or one, and accordingly describes
the relationship as optional or mandatory.

The combination of these two indicators is always in a specific order. Placed


on the outside edge of the relationship, the symbol of multiplicity comes first.
The symbol indicating whether the relationship is mandatory or optional is
shown after the symbol of multiplicity.

In crow’s foot notation:

 A multiplicity of one and a mandatory relationship is represented by a


straight line perpendicular to the relationship line.
 A multiplicity of many is represented by the three-pronged ‘crow-foot’
symbol.
 An optional relationship is represented by an empty circle.

Finally, there are four possible edges to the relationship, illustrated here:

 zero or many
 one or many

 one and only one

 zero or one
Relationship degrees make them readable as :

 One-to-one

 One-to-many

 Many-to-many
Example :

Consider the following business rules for a patient appointment system:


 
A doctor can be scheduled for many appointments, but may not have any
scheduled at all. Each appointment is scheduled with exactly 1 doctor. A
patient can schedule 1 or more appointments. One appointment is scheduled
with exactly 1 patient. An appointment must generate exactly 1 bill, a bill is
generated by only 1 appointment. One payment is applied to exactly 1 bill, and
1 bill can be paid off over time by several payments. A bill can be outstanding,
having nothing yet paid on it at all. One patient can make many payments, but a
single payment is made by only 1 patient. Some patients are insured by an
insurance company. If they are insured, they can only carry insurance with one
company. An insurance compnay can have many patients carry their policies.
For patients that carry insurance, the insurance company will make payments,
each single payment is made by exactly 1 insurance company.
 
Given the above information, the following ERD can be drawn:
 

You might also like