Difference Between Generalization and Specialization in DBMS
Table of Contents
Main Difference
The difference between generalization and specialization in DBMS is that in generalization the difference and similarities between lower entities are ignored to form higher entity whereas in specialization a higher entity is split to form lower entities.
Generalization vs. Specialization in DBMS
DBMS stands for a database management system that is a group of data that is related to each other. DBMS is a combination of programs that are used to access, maintain and utilize a database. The database is an orderly collection of data that is associated in a way. Retrieval of data is very important in database management. Retrieval of data depends on the way you store the data in your database. Generalization and specialization are very important concepts in DBMS. In generalization, the difference and similarities between lower entities are ignored to form higher entity whereas in specialization a higher entity is split to form lower entities. There are many files in the database management system, and all the files are inter related. There are many application specific software, but DBMS is not an application software it is general purpose software. The main purpose of the database management system is storing and accessing data. There are many features of a database management system such as its input data, it edits data, and it can share data, display data and can manipulate data. DBMS is also a file based system that is a set of an application program that has a purpose of carrying out the services for the user. For every database, there is a separate application program.
When we have to design any relational schema we generally use generalization. In generalization designing proceeds in a bottom up manner. In generalization, entities are figured out to create a schema that shares some similar features. Specialization is totally the opposite of generalization where there is top down manner. An entity is split in to multiple lower level entities. There is an inheritance in a specialization that is a parent child relationship. Lower level entities inherit features from higher level entries. Specialization is applied to a single entity the size of a schema is increased in specialization. These similar features are combined to form a higher level entity. In generalization what happens is that lower level entities have some characteristics in common they are clubbed to form a higher level entity. This new higher level entity will further combine with some entities, and again new higher level entity are formed. We cannot form a high level entity without any lower level entity. We can only use generalization on a group of entries. In generalization, groups are made like a group of cars, a group of bikes and group of cycles whereas the higher group is the vehicle from that vehicle higher groups are generalized that are cars, bikes, and cycles.
Comparison Chart
Generalization | Specialization |
In generalization, the difference and similarities between lower entities are ignored to form a higher entity | In specialization, a higher entity is split to form lower entities. |
Inheritance | |
There is no inheritance in generalization | There is inheritance in specialization |
Size | |
Size reduces in generalization | Size increases in specialization |
Entities | |
Generalization work on group of entities | Specialization work on single entity |
What is Generalization?
When we have to design any relational schema we generally use generalization. In generalization designing proceeds in a bottom up manner. In generalization, entities are figured out to create a schema that shares some similar features. These similar features are combined to form a higher level entity. In generalization what happens is that lower level entities have some characteristics in common they are clubbed to form a higher level entity. This new higher level entity will further combine with some entities, and again new higher level entity are formed. We cannot form a high level entity without any lower level entity. We can only use generalization on a group of entries. In generalization, groups are made like a group of cars, a group of bikes and group of cycles whereas the higher group is the vehicle from that vehicle higher groups are generalized that are cars, bikes, and cycles.
What is Specialization?
Specialization is totally the opposite of generalization where there is top down manner. An entity is split in to multiple lower level entities. There is an inheritance in a specialization that is a parent child relationship. Lower level entities inherit features from higher level entries. Specialization is applied to a single entity the size of a schema is increased in specialization.
Inheritance
Inheritance is very important. The reusability of code is very important in computer programming; inheritance allows you to reuse the same code. In inheritance, you make a new class that inherits the base class from other function. The members of base class become the member of the derived class. If we the base case is not made public it becomes private, and inheritance cannot be done. There are five types of inheritance in C++ programming language that are single inheritance in which only one super class is made, multiple inheritances in which there are many super classes, hierarchical inheritance in which there is one super class and many subclasses and multiple inheritances which is derived from a derived class. If we talk about Java, a specific keyword is used that is extended; this keyword is used to inherit class.
Key Differences
Video Explanation
ncG1vNJzZmivp6x7pbXFn5yrnZ6Ysm%2FDyKSgaJ%2BVo7KzrcuisZqsmaS7bsLSZqqpnZOerq212ZqroqeeYravecObpKxn