Bytes
rocket

Your Success, Our Mission!

6000+ Careers Transformed.

Types of Relationships

Last Updated: 9th September, 2026

Back to your café  again…

You notice something interesting:

  • One customer can place many orders
  • One order belongs to only one customer
  • Some orders contain multiple items, and one item can appear in many orders

So not all connections are the same
Some are one-to-one, some one-to-many, and some many-to-many.

That’s exactly what Types of Relationships in the ER Model explain.

sus (1).png

Relationships in ER models are classified based on how many entities are connected.

There are three main types:

  1. One-to-One (1:1)
  2. One-to-Many (1:N)
  3. Many-to-Many (M:N)

These define how data interacts inside a system.

One-to-One (1:1) Relationship

In this type, one entity is related to only one other entity.

Example:

  • One person has one passport
  • One passport belongs to one person

Code Example

Person_ID

Name

Passport_ID

1TaniyaP101

Technical Example

Person(Person_ID, Name)
Passport(Passport_ID, Person_ID)

Real Life Example

  • Person → Has → Passport
  • User → Has → Unique Profile

One-to-Many (1:N) Relationship

In this type, one entity can be related to many entities,
but each of those belongs to only one.

Example:

  • One customer places many orders
  • One order belongs to one customer

Technical Example

Customer(Customer_ID, Name)
Orders(Order_ID, Customer_ID)

Real Life Example

  1. College System
    • One teacher teaches many students
  2. E-commerce
    • One user places many orders
  3. Bank System
    • One customer has multiple accounts

Many-to-Many (M:N) Relationship

In this type, many entities are related to many others.

Example:

  • Students enroll in multiple courses
  • Each course has multiple students

Technical Example

Student(Student_ID, Name)
Course(Course_ID, Name)
Enrollment(Student_ID, Course_ID)

Here, Enrollment is a bridge (junction table)

Real Life Example

  1. College System
    • Students ↔ Courses
  2. Online Shopping
    • Orders ↔ Products
  3. Social Media
    • Users ↔ Friends

Understanding relationships is the heart of ER modeling:

1:1 → One to one
1:N → One to many (most common)
M:N → Many to many (requires bridge table)

If you get relationships right, your database will behave correctly.

Module 3: Types of RelationshipsTypes of Relationships

Top Tutorials

Logo
Data Science

Python

Python is a popular and versatile programming language used for a wide variety of tasks, including web development, data analysis, artificial intelligence, and more.

8 Modules37 Lessons112803 Learners
Start Learning
Logo
Data Science

SQL

The SQL for Beginners Tutorial is a concise and easy-to-follow guide designed for individuals new to Structured Query Language (SQL). It covers the fundamentals of SQL, a powerful programming language used for managing relational databases. The tutorial introduces key concepts such as creating, retrieving, updating, and deleting data in a database using SQL queries.

9 Modules40 Lessons16154 Learners
Start Learning
Logo
Data Science

Data Science

Learn Data Science for free with our data science tutorial. Explore essential skills, tools, and techniques to master Data Science and kickstart your career

8 Modules31 Lessons9701 Learners
Start Learning
  • Official Address
  • 4th floor, 133/2, Janardhan Towers, Residency Road, Bengaluru, Karnataka, 560025
  • Communication Address
  • Follow Us
  • facebook
    instagram
    linkedin
    twitter
    youtube
    telegram

© 2026 AlmaBetter