Entity Relationship Modeling procedure
There are two different approaches for modeling databases:
- The top-down approach, which must be used when physical entity types, entity relationships and entity relationship diagrams are not created yet. Therefore, you must manually create and define all entity types and relationships.
- The reverse engineering. This is a quick way to model entity relationship diagrams. You can select existing database or table definitions for which a diagram is created automatically. Reverse engineering can only be used in the case of LN.
The Entity Relationship Modeling top-down procedure consists of these sessions:
- Entity Types (tgerm2500m000)
- Tables by Entity Type (tgerm4100m000)
- Entity Type Relationships (tgerm3500m000)
- Entity Relationship Diagrams (tgerm1500m000)
Entity Types (tgerm2500m000)
To create the entity types, use the Entity Types (tgerm2500m000).
To define an entity type:
- In the Entity Types (tgerm2500m000) session, click .
- In the Entity Type field, specify an ID for the entity type.
- Click .
This table shows the key fields for the Entity Type Details (tgerm2100s000) session:
Field | Description |
---|---|
Owner Package | The package to which the entity type is related. |
Owner Module | The module to which the entity type is related. |
Link to Diagram | The entity-relationship diagram into which an entity type is decomposed. At a different level in the Enterprise Modeler-Tool, you can see the entity-type relationship between the current entity type and other entity types. |
Entity Type Category | If this check box is selected, the entity type is a physical entity type. Or a logical entity type that is related to the Baan package. |
Associative Entity Type | If this check box is selected, the entity type serves as a link between two other entity types that have a many-to-many relationship between them. |
Tables by Entity Type (tgerm4100m000)
Select one or more tables from the Table Definitions (ttadv4526m000) session. To link those tables to the selected entity type, use the Tables by Entity Type (tgerm4100m000) session.
To start this session:
- Go to the Entity Types (tgerm2500m000) session.
- Click the appropriate menu.
- Select
One entity type can be linked to several tables. The interdependent relations between these tables are shown at different levels in the Modeler.
Entity Type Relationships (tgerm3500m000)
To list and define entity type relationships, use the Entity Type Relationships (tgerm3500m000) session. The relationships that are listed in the Entity Type Relationships (tgerm3500m000) session are established between the entity types listed in the Entity Types (tgerm2500m000) session.
To define entity type relationships, in the Entity Type Relationship Details (tgerm3100s000) session, select the entity types between which relationships are to be established. You can also define the cardinality of the relationship between the selected entity types.
In the case of an M:N relationship, an associative entity type can be created. A table can be selected from the Table Definitions (ttadv4526m000) session to serve as a link between two entity types.
To define a relationship between two entity types:
- In the Data Entity Relationship field, specify an ID for the relationship.
- In the From Entity Type field, select the first entity type that is involved in the relationship.
- In the To Entity Type field, select the other entity type that is involved in the relationship.
- In the Min Cardinality From - To field, specify the number of possible entities for each entity type of a pairing for the entity type you selected in the From Entity Type field.
- In the Min Cardinality To - From field, specify for the entity type in the To Entity Type field, the number of possible entities per entity type of a pairing.
- Click
This table shows the key fields for the Entity Type Relationship Details (tgerm3100s000) session:
Field | Description |
---|---|
Relationship is Subtype | If this check box is selected, the entity-type relationship is between a subtype and a supertype entity type; it is used to indicate that the supertype’s attribute also applies to the subtype. |
Physical Database Relation exists | If this check box is selected, the entity-type relationship is between entity types that have tables from the LN data dictionary linked to them. |
Associative Table | An LN table that is used to link two entity types that have a many to many relationship between them. |
Infinite | If this check box is selected, the maximum to-from relationship is infinite. |
Entity Relationship Diagrams (tgerm1500m000)
To create and maintain the entity-relationship diagrams, use the Entity Relationship Diagrams (tgerm1500m000) session. An entity-relationship diagram is a graphical design of the relational data model structure. The diagram shows a multilevel structure that consists of entity types and entity-type relationships.
To create an entity-type relationship diagram:
- In the Entity Rel. Diagram field, specify an ID for the entity relationship diagram.
- In the Owner field, select the LN user for the entity relationship diagram.
- Select who is authorized to modify the diagram by selecting one of the check boxes under To be modified by.
- Click