Previous Topic: Define General Properties for an Attribute

Next Topic: Specify the Logical Data Type for an Attribute

Specify the Validation Rule and Default Value for an Attribute

You can use the Constraint tab in the Attribute Editor to specify the validation rule and the default value for an attribute.

To specify the validation rule and default value for an attribute

  1. Right-click the attribute on the diagram for which you want to specify a validation rule and default value and click Attribute Properties.

    The Attribute Editor opens.

  2. Click the Constraint tab and work with the following options.
    Check Constraints

    Specifies the validation rule to attach to the selected attribute. Select the validation rule that you want from the drop-down list. You can also use the drop-down list to open the Validation Rule Editor to view or modify an existing validation rule or create a new one. If the Use Inherited Constraint check box is selected this means that this property is inherited from the attribute's domain. If you do not want this property to be inherited, simply clear the check box and select a validation rule from the drop-down list.

    Default

    Specifies the default value to attach to the selected attribute. Select the default value that you want from the drop-down list. You can also use the drop-down list to open the Default Value Editor to view or modify an existing default value or create a new one. If the Use Inherited Default Value check box is selected this means that this property is inherited from the attribute's domain. If you do not want this property to be inherited, simply clear the check box and select a default value from the drop-down list.

  3. Click Close.

    The validation rule and default value is specified and the Attribute Editor closes.

More information:

Specify the Logical Data Type for an Attribute

Attributes