Siebel Order Management Infrastructure Guide > Data Validation Manager > Process of Administering Data Validation Rules >

Defining Validation Rules


For each rule set, you define one or more validation rules. These rules represent the validation criteria.

You can only define rules for validation rule sets that have a status of In Progress.

This task is part of Process of Administering Data Validation Rules.

To define a validation rule

  1. Navigate to the Administration - Data Validation screen.
  2. In the Rule Sets list, select a rule set with a status of In Progress and drill down on the rule set name.
  3. Click the Rules view tab.
  4. In the Rules list, add a new record, and complete the necessary fields. Some fields are described in the following table:
    Field
    Comments

    Sequence #

    Identifies the numeric sequence of this rule in the rule set. The application evaluates rules in numerical order based on this number.

    Business Component

    The business component upon which the rule is based.

    Expression

    A statement expressed in Siebel Query Language. The application evaluates whether the expression is true or false. If true, the data validation manager proceeds to evaluate the next rule. If false, the application performs the actions defined for the rule.

    You can refer to a business component field value using the notion [Field]. For example, if the business component of the rule is Opportunity, then an expression [Sales Stage] IS NOT NULL means that you want to know of the Sales Stage field of the Opportunity business component contains a value or not.

    You can use the syntax [BC.Field] to refer to a field of a business component different from the one of the validation rule. For example, you can have a rule which has its business component set as Opportunity. You can write an expression [Sales Stage] IS NOT NULL AND [Account.Status] = "Active". [Account.Status] refers to the Status field of the Account business component. Without a prefix, [Sales Stage] refers to the Sales Stage field of the business component (that is, Opportunity) of the rule.

    You can also use the syntax [&Argument] to refer to a rule set argument. For example, you can have a rule expression [&Answer] = Yes. Here the rule set argument Answer has already been defined in the Arguments List Applet. Once defined, the argument becomes a business service input argument which you can populate with dynamic values at run time (for example, through a workflow).

    You can either enter the statement directly in the field or click the Expression select button to launch the Expression Designer. The Expression Designer allows you to construct an expression by pointing and clicking on a pop up window, perform syntax validation, and lookup definitions of built-in functions supported by the Siebel Query Language.

    For more information on the Expression Designer, see Developing and Deploying Siebel Business Applications.

    Message

    Displays the text of the error message from the Return Code field.

    If the expression is evaluated to be false, the application either displays the error message or writes it to a log file. The maximum number of characters is 250.

    For more information viewing the validation log file, see Viewing a Validation History.

    Apply To

    This field takes on two values: Current Record and All Records.

    When Current Record is chosen, Data Validation Manager applies the validation rule to the current active business component record. When All Records is chosen, Data Validation Manager applies the validation rule to all business component records.

    If the business component on the rule is the same as the one on the rule set, then this field is read only. If the business components on the two are not the same, you can choose Current Record or All Records.

    Return Code

    Select the return code and error message for this rule.

    The Validation Messages dialog box allows you to select codes and associated error messages that you defined in the step Defining Error Messages for Data Validation.

    CAUTION:  If you type a return code rather than selecting if from the dialog box, the error message is not copied into the rule. The error message for this rule will be blank.

    Start Date

    Corresponds to the time when the rule becomes effective. A rule is only evaluated if the Start Date is equal to or earlier than the current date.

    End Date

    Specifies the last date this rule can be used. If not populated, the rule set never expires. A rule is only evaluated if the End Date is equal to or later than the current date.

  5. Below the Rules list, click the Rule Detail view tab and complete the necessary fields. Some fields are described in the table that follows.
    Field
    Comments

    Stop on Error

    If the expression is evaluated to be false and this field is checked (TRUE), the application will ignore all subsequent rules.

    Immediate Display

    Defines error message behavior. If the expression is evaluated to be false, and both Immediate Display and Stop on Error flags are checked (enabled), the application immediately displays the specified message.

    NOTE:  If, for the rule set, Aggregate Errors is enabled, the Immediate Display flag for each rule is ignored. Instead, the application aggregates all error messages of the rules that are FALSE into one string, and then display the aggregated error message to the end user.

    Message

    The text of the error message. If the expression is evaluated to be false, the application either displays the error message or writes it to a log file. The maximum number of characters is 250.

    For more information viewing the validation log file, see Viewing a Validation History.

Siebel Order Management Infrastructure Guide Copyright © 2008, Oracle and/or its affiliates. All rights reserved. Legal Notices.