Using Domains

From ER/Studio Business Architect
Jump to: navigation, search

Go Up to Reference Objects

Domains are reusable attribute templates that promote consistent domain definitions. You construct domains as you would attributes, specifying a name, datatype properties, null status, default values, and validation rules. After creating domains, you can re-use them in your data model by applying them to attributes and table columns.

For more information see

By defining a Domain, you can then propagate changes to the underlying domain definition to all attributes and table columns that reference it.

Note: Domains are not visualized on diagrams so the Domain element icon is not available on the Reference Object’s toolbar or palette.

One important method for enforcing business rules is to define and to apply domain restrictions. Domain integrity refers to the rules governing what values an attribute can take. By restricting and validating an attribute's values, you can implement important business rules such as ensuring that a checking account maintains a positive balance, or preventing the entry of invalid phone numbers.

Dragging and Dropping Domains on Business Entities

Dragging/dropping of Domains to Business Entities are allowed. A Business Attribute is created using the domain name if an attribute with that name doesn’t already exist. If an attribute with that name already exists, a unique name is assigned to the attribute.

Importing ER/Studio Data Architect Domains as ER/Studio BA Domains

  • The ER/Studio DA domain data type will be created as the ER/Studio BA domain’s data type.
  • The ER/Studio DA width will be created as the ER/Studio BA domain’s width.
  • The ER/Studio DAscale will be created as the ER/Studio BA domain’s scale.
  • The ER/Studio DA “allow nulls” property will be created as the ER/Studio BA domain’s “Optionality” property. Allow nulls is equivalent to ‘optional’.
  • The enforcement options on the domains will be set from the “allow override” options of the ER/Studio DA domain.
  • The business attributes will be bound to the domains as per the ER/Studio DA model.
  • Since domains do not enforce description/notes from the domains, the descriptions and notes will be set on the business attribute, but there is no enforcement from that point on. Same for attribute names.

Importing ER/Studio Domains as Business Elements Referencing Domains

  • The domain’s name will be created as both the business element’s name and the ER/Studio BA domain’s name. The “enforce name” option will be cleared on the business element (i.e. not enforced).
  • The domain’s description will be created as the business element’s description.
  • The domain’s notes will be created as the business element’s notes.
  • The domain’s data type will be created as the ER/Studio BA domain’s data type.
  • The ER/Studio DA width will be created as the ER/Studio BA domain’s width.
  • The ER/Studio DA scale will be created as the ER/Studio BA domain’s scale.
  • The ER/Studio DA “allow nulls” property will be created as the ER/Studio BA domain “Optionality” property.
  • The enforcement options on the domains will be set from the “allow override” options of the ER/Studio DA domain.
  • The business element will point to the domain.
  • The business attributes will be bound to the business elements as per the ER/Studio DA model.