Previous Topic: How erwin Data Modeler Generates Validation RulesNext Topic: Copy Valid Values from a Validation Rule


Add a Validation Rule

Add validation rules to enforce the business rules of your organization. The rules that you create can establish a value, a list of values, or a range of acceptable values to store in a table, column, entity, or attribute.

To add a validation rule

  1. Click Validation Rules on the Model menu.

    The Validation Rule Editor opens.

  2. Click the New New icon in property editors to create a new object button on the toolbar.

    A new validation rule with a default name is added to the Navigation Grid.

  3. Work with the following options:
    Physical Name

    Specifies the physical name of the validation rule. You can change the name in this field.

    Type

    Specifies the validation rule type. You can select one of the following options:

    User-Defined

    Specifies to use an expression to create a server-side validation expression. This expression is entered in the General tab.

    MinMax

    Specifies to use minimum and maximum values. The values are specified in the General tab.

    Valid Values

    Specifies to create a set of valid values. The values are specified in the General tab.

    Physical Only

    Specifies that the validation rule only applies to a physical model.

  4. Click the General tab and work with the following options. The options available are based on the options you selected in the Type drop-down in the Navigation Grid.
    <validation rule> Expression

    Lets you enter an expression in the correct syntax for the selected server to create a server-side validation expression.

    Note: These options are only available if you selected the User-Defined option in the Type drop-down in the Navigation Grid.

    <validation rule> Properties

    Specifies the validation rule properties.

    <validation rule> Min/Max Properties

    Specifies the minimum and maximum values.

    <validation rule> Expression

    Lets you enter an expression in the correct syntax for the selected server to create a server-side validation expression.

    Note: These options are only available if you selected the MinMax option in the Type drop-down in the Navigation Grid.

    <validation rule> Properties

    Specifies the validation rule properties.

    <validation rule> Valid Values

    Specifies the valid values. In addition to sorting, creating, deleting and reordering valid values, you can use the toolbar to import valid values.

    <validation rule> Expression

    Lets you enter an expression in the correct syntax for the selected server to create a server-side validation expression.

    Note: These options are only available if you selected the Valid Values option in the Type drop-down in the Navigation Grid.

  5. Click Close.

    The validation rule is added and the Validation Rule Editor closes.

More information:

Specify Minimum or Maximum Values for a Validation Rule

Create a Valid Value List

Copy Valid Values from a Validation Rule

Delete a Valid Value

Assign Validation Rule UDP Values