Siksha Sarovar

Siksha Sarovar (sikshasarovar.com) is a free educational web application that helps students in India learn programming and prepare for academic and competitive exams. The platform offers structured coding courses (C, C++, Python, Java, HTML, CSS, PHP, Power BI, AI, Machine Learning, Data Science), complete university curriculum notes for BCA/MCA students with previous year question papers, Class 10 and Class 12 CBSE/HBSE school notes, and dedicated preparation material for SSC, UPSC, Banking, Railway and other government exams. Browsing the site is completely free and requires no account. Users may optionally sign in with Google solely to save their learning progress, quiz scores and personal preferences across devices.

Privacy Policy | Terms of Service | Contact Siksha Sarovar | About Siksha Sarovar

v4.0.9 · PWA
Siksha Sarovar logo
Siksha Sarovar
Your Learning Universe

Siksha Sarovar is a free e-learning platform for coding courses, BCA university notes and competitive exam preparation. Optional Google sign-in saves your learning progress across devices.

Initializing knowledge base…
Compiling modules 0%

Unit 1: Relationship Types and Constraints

Lesson 9 of 28 in the free Database Management Systems notes on Siksha Sarovar, written by Rohit Jangra.

9.1 Relationship Concepts

A Relationship is an association among several entities. For example, Student 'Amit' participates in a relationship with Course 'DBMS'.

9.2 Degree of a Relationship

The number of entity types participating in a relationship.

  • Unary (Degree 1): One entity type related to itself. (e.g., Employee manages Employee).
  • Binary (Degree 2): Two entity types. (Most common).
  • Ternary (Degree 3): Three entity types. (e.g., Physician prescribes Medicine to Patient).

9.3 Cardinality Ratios (Mapping Constraints)

This defines the maximum number of relationship instances an entity can participate in.

RatioDescriptionReal-world Example
1:1 (One-to-One)Each entity in A is linked to at most one in B.Manager -> Department
1:N (One-to-Many)One entity in A linked to many in B.Department -> Employees
M:1 (Many-to-One)Many entities in A linked to one in B.Students -> College
M:N (Many-to-Many)Many in A linked to many in B.Students -> Courses

9.4 Participation Constraints

Defines whether every entity in a set must participate in the relationship.

  1. Total Participation (Existence Dependency): Every entity in the set must be related to an entity in the other set.
  • Notation: Double Line.
  • Example: Every Employee must work for a Department.
  1. Partial Participation: Only some entities in the set participate.
  • Notation: Single Line.
  • Example: Not every Employee must be a Manager.