Working with generalization sets

A generalization set is a collection of one or more generalizations that are used to better define data.

A generalization is a binary relationship that relates a specific entity (or subtype) to a more general entity (or supertype). A generalization set defines a particular grouping of generalizations that describe the way in which a supertype is divided into subtypes. Each generalization set is defined by a defining set or discriminator.For example, you decide to have a supertype entity, Vehicles and decide to divide it into two groupings of subtypes, based on (or the discriminator of) Terrain type and Propulsion type. This generalization set is divided into two generalizations, Land Vehicles and Air Vehicles, which are defined by the Terrain discriminator.

Each generalization set is defined by a defining attribute, found in the supertype entity of the generalization set.

The Vehicles generalization set

You are a data modeler for a vehicle manufacturer. You are currently working on a data model that is intended to track vehicle sales and trends. In addition to sales, customer, and employee data, you model the different vehicles that are sold through your company. Since your company sells airplanes in addition to cars, you need to model your data accordingly.

You have an entity, Vehicles, that contains many attributes that model information about cars, airplanes, and boats. To make it easier to track vehicle data, you decide to create generalizations that subtype the vehicles into three discriminators: land vehicles, air vehicles, and sea vehicles. These sets are based on the Terrain discriminator. Other subtypes based on the Propulsion discriminator are gas vehicles, electric vehicles, or other. Using the diagram editor, you create a generalization set, using the Type attribute of the Vehicles entity as the defining attribute.

The Vehicles entity is the supertype entity of this generalization set. You have two generalization sets, TerrainSet and PropulsionSet, that are the subtypes of the supertype entity, Vehicles. Then, you use the Properties view of a generalization set to define the Type attribute as the defining attribute.


Feedback