0

When drawing ER diagram with Chen notation. Do all 1:N relationship be drawn with Total participation constraints double lines? For example: one Invoice can have multiple payments. And a payment must have a invoice number as a payment is done for an invoice. This has 1:n relationship so how do i put this in a diagram? erd example

Shafraz Kamil
  • 31
  • 1
  • 4

1 Answers1

0

No, all 1:N relationships don't require full participation of the entity set on the many side. A person can be in one building, while a building can hold multiple persons, but a building can be empty, and people can be outside.

In your example, must every Payment necessarily be related to an Invoice? If so, then indicate total participation of Payment in the Received relationship by using a double association line.

A double-bordered diamond indicates an identifying relationship. Using that would indicate that a Payment isn't identified by its own attributes, but by its Invoice and a weak key. A weak key is usually an ordinal or role that isn't unique by itself, but serves to subdivide the parent entity. For example, consider a model where Invoices have numbers, and Payments are identified by an Invoice number together with a sequence number to indicate the 1st, 2nd or 3rd payment on that Invoice.

Weak entity sets necessarily participate totally in their identifying relationships, but keep in mind that total participation doesn't imply an identifying relationship.

See also my answer to Is optionality (mandatory, optional) and participation (total, partial) are same?

reaanb
  • 9,806
  • 2
  • 23
  • 37