Bird
Raised Fist0
DBMS Theoryknowledge~5 mins

Entity-Relationship model in DBMS Theory - Cheat Sheet & Quick Revision

Choose your learning style10 modes available
Recall & Review
beginner
What is an Entity in the Entity-Relationship model?
An Entity is a real-world object or thing that can be distinctly identified. It can be a person, place, event, or concept.
Click to reveal answer
beginner
Define a Relationship in the Entity-Relationship model.
A Relationship shows how two or more entities are connected or associated with each other in the real world.
Click to reveal answer
beginner
What is an Attribute in the Entity-Relationship model?
An Attribute is a property or characteristic of an entity or relationship, like a name, age, or date.
Click to reveal answer
intermediate
Explain the concept of Cardinality in the Entity-Relationship model.
Cardinality defines the number of instances of one entity that can be associated with instances of another entity, such as one-to-one, one-to-many, or many-to-many.
Click to reveal answer
beginner
What is a Primary Key in the context of the Entity-Relationship model?
A Primary Key is an attribute or set of attributes that uniquely identifies each entity instance in an entity set.
Click to reveal answer
Which of the following best describes an Entity in the ER model?
AA property of a relationship
BA real-world object or thing
CA connection between two databases
DA type of database query
What does Cardinality specify in an ER diagram?
AThe number of instances of one entity related to another
BThe number of relationships in the model
CThe number of attributes an entity has
DThe size of the database
Which symbol is commonly used to represent an Entity in an ER diagram?
ARectangle
BDiamond
COval
DArrow
What is the role of an Attribute in the ER model?
ATo connect entities
BTo represent database users
CTo define database tables
DTo describe properties of entities or relationships
A Primary Key in an entity is used to:
ADescribe the entity's attributes
BLink two entities
CIdentify each entity instance uniquely
DShow the relationship type
Explain the main components of the Entity-Relationship model and their roles.
Think about objects, their connections, and properties.
You got /5 concepts.
    Describe how cardinality affects the way entities relate to each other in an ER diagram.
    Consider how many of one entity can connect to another.
    You got /4 concepts.

      Practice

      (1/5)
      1. What does an Entity-Relationship (ER) model primarily represent in a database?
      easy
      A. Entities, their attributes, and relationships
      B. Only the tables and columns
      C. The programming code for database queries
      D. The physical storage details of data

      Solution

      1. Step 1: Understand the purpose of ER model

        The ER model is designed to visually represent entities, their attributes, and how they relate to each other in a database.
      2. Step 2: Compare options with ER model definition

        Options B, C, and D describe other aspects of databases but not the ER model's main focus.
      3. Final Answer:

        Entities, their attributes, and relationships -> Option A
      4. Quick Check:

        ER model = Entities + Attributes + Relationships [OK]
      Hint: ER model = entities + attributes + relationships [OK]
      Common Mistakes:
      • Confusing ER model with physical database design
      • Thinking ER model shows SQL code
      • Assuming ER model only shows tables
      2. Which shape is commonly used to represent an entity in an ER diagram?
      easy
      A. Diamond
      B. Arrow
      C. Oval
      D. Rectangle

      Solution

      1. Step 1: Recall ER diagram symbols

        In ER diagrams, entities are shown as rectangles, relationships as diamonds, and attributes as ovals.
      2. Step 2: Match shapes to their meanings

        Since the question asks about entities, the correct shape is rectangle.
      3. Final Answer:

        Rectangle -> Option D
      4. Quick Check:

        Entity = Rectangle [OK]
      Hint: Entity = rectangle, Relationship = diamond, Attribute = oval [OK]
      Common Mistakes:
      • Mixing entity and relationship shapes
      • Choosing oval for entity
      • Confusing arrows with entities
      3. Consider an ER diagram where a 'Student' entity is connected to a 'Course' entity with a 'Registers' relationship. If one student can register for many courses, but each course can have many students, what type of relationship is this?
      medium
      A. One-to-One
      B. Many-to-Many
      C. Many-to-One
      D. One-to-Many

      Solution

      1. Step 1: Analyze the relationship cardinality

        One student can register for many courses, and each course can have many students.
      2. Step 2: Identify the relationship type

        This means multiple students relate to multiple courses, which is a many-to-many relationship.
      3. Final Answer:

        Many-to-Many -> Option B
      4. Quick Check:

        Multiple students and courses = Many-to-Many [OK]
      Hint: Both sides many = Many-to-Many relationship [OK]
      Common Mistakes:
      • Choosing One-to-Many when both sides are many
      • Confusing direction of relationship
      • Ignoring the 'many' on both sides
      4. In an ER diagram, a relationship is shown as a rectangle instead of a diamond. What is the error in this diagram?
      medium
      A. Attribute symbol is incorrect; should be rectangle
      B. Entity symbol is incorrect; should be oval
      C. Relationship symbol is incorrect; should be diamond
      D. No error; rectangle is correct for relationships

      Solution

      1. Step 1: Recall ER diagram symbols

        Relationships are represented by diamonds, not rectangles.
      2. Step 2: Identify the mistake

        Using a rectangle for a relationship is incorrect; rectangles represent entities.
      3. Final Answer:

        Relationship symbol is incorrect; should be diamond -> Option C
      4. Quick Check:

        Relationship = Diamond, not rectangle [OK]
      Hint: Relationship = diamond, not rectangle [OK]
      Common Mistakes:
      • Confusing entity and relationship symbols
      • Thinking rectangles can represent relationships
      • Ignoring standard ER diagram conventions
      5. You want to design an ER diagram for a library system where each book can have multiple authors, and each author can write multiple books. Additionally, each book has a unique ISBN and a title. How should you represent the authors and books relationship and the attributes in the ER model?
      hard
      A. Use entities 'Book' and 'Author' connected by a many-to-many relationship; attributes ISBN and title belong to 'Book'
      B. Use a single entity 'BookAuthor' with attributes ISBN, title, and author name
      C. Use entities 'Book' and 'Author' connected by a one-to-many relationship; ISBN and title as attributes of 'Author'
      D. Use entities 'Book' and 'Author' with no relationship; attributes ISBN and title belong to 'Author'

      Solution

      1. Step 1: Identify entities and attributes

        'Book' and 'Author' are entities. ISBN and title are attributes of 'Book'.
      2. Step 2: Determine relationship type

        Since books can have multiple authors and authors can write multiple books, the relationship is many-to-many.
      3. Step 3: Match options to correct design

        Use entities 'Book' and 'Author' connected by a many-to-many relationship; attributes ISBN and title belong to 'Book' correctly uses two entities connected by a many-to-many relationship and assigns attributes properly.
      4. Final Answer:

        Use entities 'Book' and 'Author' connected by a many-to-many relationship; attributes ISBN and title belong to 'Book' -> Option A
      5. Quick Check:

        Many-to-many + correct attributes = Use entities 'Book' and 'Author' connected by a many-to-many relationship; attributes ISBN and title belong to 'Book' [OK]
      Hint: Many-to-many for multiple authors/books; attributes with correct entity [OK]
      Common Mistakes:
      • Using one-to-many instead of many-to-many
      • Assigning book attributes to author
      • Combining entities incorrectly
      Recommended

      Ready to prove it?

      Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

      10 questions~5 mineasy hard