- Trending Categories
- Data Structure
- Operating System
- C Programming
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Types of DBMS Entities and their examples
Entity in DBMS can be a real-world object with an existence, For example, in a College database, the entities can be Professor, Students, Courses, etc.
Entities has attributes, which can be considered as properties describing it, for example, for Professor entity, the attributes are Professor_Name, Professor_Address, Professor_Salary, etc. The attribute value gets stored in the database.
Example of Entity in DBMS
Let us see an example −
Here, Professor_Name, Professor _Address and Professor _Salary are attributes.
Professor_ID is the primary key
Types of DBMS Entities
The following are the types of entities in DBMS −
The strong entity has a primary key. Weak entities are dependent on strong entity. Its existence is not dependent on any other entity.
Strong Entity is represented by a single rectangle −
Continuing our previous example, Professor is a strong entity here, and the primary key is Professor_ID.
The weak entity in DBMS do not have a primary key and are dependent on the parent entity. It mainly depends on other entities.
Weak Entity is represented by double rectangle −
Continuing our previous example, Professor is a strong entity, and the primary key is Professor_ID. However, another entity is Professor_Dependents, which is our Weak Entity.
This is a weak entity since its existence is dependent on another entity Professor, which we saw above. A Professor has Dependents.
Example of Strong and Weak Entity
The example of a strong and weak entity can be understood by the below figure.
The Strong Entity is Professor, whereas Dependent is a Weak Entity.
ID is the primary key (represented with a line) and the Name in Dependent entity is called Partial Key (represented with a dotted line).
- Explain the stages and their examples of database development lifecycle (DBMS)?
- Different Types of Transformers and Their Applications
- Types of Motor Enclosures and Their Applications
- Internet Cookies and Their Types
- Different Types of Electric Lamps and Their Features
- Different Types of Railway Services and Their Characteristics
- Types of dependencies in DBMS
- HTML Entities
- Variables, their types, and Scope in C++
- Digital Electronics Flip-flops and their Types
- Types of Entity Relationships in DBMS
- Various Types of Keys in DBMS
- Explain attributes and the different types of attributes in DBMS?
- Flip-flop types and their Conversion in C++
- Data types ranges and their macros in C++