TOPIC 2 : Introduction To The RDBMS Flashcards
What is the purpose of the ER Model in DBMS?
The ER Model helps design and show how data is connected.
It uses entities (objects) and relationships (links between objects).
What is an “Entity”?
An entity is a real thing or person stored in the database, like a student or teacher.
What is an “Entity Set”?
An entity set is a group of the same kind of entities.
For example, all students together make up the student entity set.
What are “Attributes”?
Attributes are details about an entity.
For a student, attributes can be name, age, or roll number.
What is a “Simple Attribute”?
A simple attribute has a single, basic value, like a student’s age.
What is a “Composite Attribute”?
A composite attribute has multiple parts.
For example, a student’s address can include street, city, and zip code.
What is a “Derived Attribute”?
A derived attribute is calculated from other data.
For example, age can be derived from a student’s birth date.
What is a “Single-Valued Attribute”?
It’s an attribute that has only one value.
Example: A student’s roll number.
What is a “Key” in the ER Model?
A key is an attribute that can uniquely identify an entity.
For example, a student’s roll number can identify a specific student.
What are the types of Keys in the ER Model?
- Super Key
- Candidate Key
- Primary Key
What is a “Relationship” in the ER Model?
A relationship shows how one entity is connected to another.
Example: A class is related to a student because students study in classes.
What is the “degree” of a relationship?
- Binary relationship involves 2 entities.
- Ternary relationship involves 3 entities.
What is an ER Diagram?
An ER Diagram is a visual map of data showing entities, their attributes, and how they are related to each other.
Can you give an example of an ER Diagram?
Yes! An ER diagram can show that:
- A Developer creates a Website
- A Visitor visits the Website
What does a rectangular box represent in an ER Diagram?
A rectangular box represents an Entity in an ER Diagram.
How are relationships between entities represented in an ER Diagram?
Relationships are represented by a Rhombus (diamond shape) between two or more entities.
How are attributes for an entity represented in an ER Diagram?
Attributes are represented by an Ellipse connected to the entity.
How is a weak entity represented in an ER Diagram?
A Weak Entity is represented by double rectangular boxes and is usually connected to another entity.
How is a key attribute represented in an ER Diagram?
A Key Attribute is represented by underlining the attribute name inside the ellipse.
How is a derived attribute represented in an ER Diagram?
A Derived Attribute is represented by a dotted ellipse inside the main ellipse.
Example: Age derived from Date of Birth.
How is a multivalued attribute represented in an ER Diagram?
A Multivalued Attribute is represented by a double ellipse, one inside another.
What is a composite attribute in an ER Diagram?
A Composite Attribute is an attribute that has other attributes.
What is an entity in an ER Diagram, and how is it represented?
An Entity can be any object, place, person, or class.
It is represented by a rectangle in an ER Diagram.
Example: In an organization, Employee, Manager, Department, and Product are entities.
What is a weak entity, and how is it represented in an ER Diagram?
A Weak Entity depends on another entity and doesn’t have a key attribute of its own.
It is represented by a double rectangle.
What is an attribute in an ER Diagram, and how is it represented?
An Attribute describes a property or characteristic of an entity, such as Name, Age, or Address.
It is represented by an ellipse.
What is a key attribute in an ER Diagram, and how is it represented?
A Key Attribute is the main characteristic of an entity, representing the Primary Key.
It is shown by an ellipse with the text underlined.
What is a composite attribute, and how is it represented?
A Composite Attribute is an attribute that has its own attributes.
It is represented by multiple connected ellipses.
What is a relationship in an ER Diagram, and how is it represented?
A Relationship describes the relation between entities and is represented by a diamond or rhombus.
What are the three types of relationships between entities in an ER Diagram?
The three types of relationships are:
a) Binary Relationship
b) Recursive Relationship
c) Ternary Relationship
What is a binary relationship in an ER Diagram?
A Binary Relationship is a relationship between two entities.
It can be
1) One-to-one
2) One-to-many
3) Many-to-one
4) Many-to-many.
What is a one-to-one relationship?
In a One-to-One relationship, one entity is related to only one other entity.
Example: A student enrolls in only one course, and that course has only one student.