Entities contain attributes, which are characteristics or modifiers, qualities, amounts, or features. An attribute is a fact or nondecomposable piece of information about an entity. Later, when you represent an entity as a table, its attributes are added to the model as new columns.
You must identify the entities before you can identify the database attributes. After you determine the entities, ask yourself, "What characteristics do I need to know about each entity?" For example, in an address entity, you probably need information about street, city, and zip code. Each of these characteristics of the address entity becomes an attribute.
To select attributes, choose ones that have the following qualities:
Include only attributes that are useful to the database users.
An attribute that can be derived from existing attributes (for instance, through an expression in a SELECT statement) should not be part of the model. Derived data complicates the maintenance of a database.
At a later stage of the design, you can consider adding derived attributes to improve performance, but at this stage exclude them. For information about how to improve the performance of your database server, see your IBM Informix: Performance Guide.
An attribute can contain only single values, never lists or repeating groups. Composite values must be separated into individual attributes.
For example, you would want to enter only date values in a birthday attribute, not names or telephone numbers.
The rules for how to define attributes are the same as those for how to define columns. For information about how to define columns, see Placing Constraints on Columns.
The following attributes are added to the telephone directory example to produce the diagram that Figure 15 shows:
For now, list the attributes for the telephone directory example with the entities with which you think they belong. Your list should look like Figure 11.
An additional data object is the entity occurrence. Each row in a table represents a specific, single occurrence of the entity. For example, if customer is an entity, a customer table represents the idea of customer; in it, each row represents one specific customer, such as Sue Smith. Keep in mind that entities become tables, attributes become columns, and entity occurrences become rows.
Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]