Entity relationships are metadata. Entity relationships define the different ways of entity records can be associated to different entity records from other entities or the same entity. Entity relationships allows the query to retrieve data efficiently.
Types of Entity relationships:
There are two types of entity relationships
Many related entity records associated with a single entity record (1:N) ,a parent/child relation.
Many entity records are associated with many other entity records. A N to N( N:N) relation.
Entity relationship (1:N) do the following tasks, other than define the relations between the entities:
- If record deleted on the parent entity then the record associated in the child entities also deleted.
- When assign a record to a new owner, associated records also assign to the new owner.
- How the record and related records will be visible to the users.