One-to-one relationships

One to many relationship is a type of cardinality that refers to a relationship between two entities in an entity relational diagram (between two tables in a database). A simple example would be a binding between the entities person and birth_certificate. Each person must have their own birth certificate.

Graphically, the one to one relationship is shown as follows:

one-to-one relationship

One-to-one relationships in Luna Modeler

Every time you create a new relationship between tables, a one-to-many relationship is created. To change to a one-to-one relationship, edit the properties of the relationship. Just set the cardinality value to One and the notation will change.

one-to-one relationship settings

Alternate solution

If it is not necessary to keep records of birth certificate entries in another database table, you can store these records in the same table and use e.g. JSON format which can be further structured.

script with json

Types of relationships in ER diagrams

Get started today and try Luna Modeler – ER diagram tool!

Download Read Quick Start Guides