Database Engineering
  • Need of Database
  • Database and Database Management System
  • What is Relational Database Model ?
  • Installing Postgresql
    • Installing PostgreSQL on Linux
    • Installing PostgreSQL on Windows
    • Installing PostgreSQL on Mac
    • Postgres in Docker
  • What happens during the initial installation ?
    • Roles, Users & Groups
    • More examples on Roles
  • Sample Databases
    • DVD Rental Database
  • Querying Data
    • SELECT Query
    • Column Aliases
    • Order By
    • SELECT DISTINCT
    • DB-TASK-001
  • Filtering Data
    • WHERE ?
    • AND Operator
    • OR Operator
    • LIMIT
    • FETCH
    • IN
    • BETWEEN
    • LIKE
    • SIMILAR TO
    • IS NULL
    • ESCAPE
    • DB-TASK-002
  • Entity Relationship Diagram
    • What is an ER Diagram ?
    • Entity
    • Identifiers
    • Relationship
    • Attributes
    • Cardinality
    • Entity Relationship Diagram Tutorial
    • DB-TASK-003
  • Joins
    • Joins
    • Joins With Employee and Departments
  • Joins on E-Commerce
Powered by GitBook
On this page
  1. Entity Relationship Diagram

Cardinality

PreviousAttributesNextEntity Relationship Diagram Tutorial

Last updated 5 months ago

Defines the numerical attributes of the relationship between two entities or entity sets. The three main cardinal relationships are one-to-one (1:1), one-to-many (1:m), and many-many (m:n).

A one-to-one example: would be one student associated with one login name.

A one-to-many example (or many-to-one, depending on the relationship direction): One product line contains multiple products.

Many-to-many example: Students as a group are associated with multiple faculty members (teachers), and faculty members (teachers) in turn are associated with multiple students.

Cardinality views: Cardinality can be shown as look-across or same-side, depending on where the symbols are shown.

Cardinality constraints and obligated (or participation constraint): The minimum or maximum numbers that apply to a relationship