Rule Violation Messages

Previous Next

See Also

Rule violation messages include:

· User-defined constraints
· Table constraints.

 

· Domain constraints.
· Built-in constraints
· Subtype Definitions: totality and exclusivity.

 

· Relationship checks: Min/Max No. of Children, Foreign Key Mandatory.

 

· Domain checks: Allowed values, Min/Max Values, Uppercase.

 

· Column checks: Mandatory, Unique Key.

All rule violation messages have the following structure in common:

<uslng:messages – common attributes - >

<uslng:message - common attributes - source="..." >

   <uslng:context>

   ...

   </uslng:context>

   <uslng:violation | uslng:correction>

       <uslng:message -common attributes- >

        -- constraint message --

       </uslng:message>

   </uslng:violation | uslng:correction>

</uslng:message>

</uslng:messages>

This structure may be included in another message. For example, a batch violation looks like:

<uslng:messages app-interface="batch" - common-attributes - >

<uslng:message msg-code="424" -common-attributes- >

   Failed to execute SQL statement in SQL task "

   <uslng:param name="Task">DC-DOM_UPD_MSG-AND-RESTR</uslng:param>

". Statement:

<uslng:param name="Statement">insert into LNG_T1(pk, col1) values(4,6)</uslng:param>

   Report:

   <uslng:param name="Report">

   <uslng:messages -common-attributes-

       <uslng:message -common attributes-

       <uslng:context>

           <uslng:execution-stack> ... </uslng:execution-stack>

           <uslng:record> ... </uslng:record>

       </uslng:context>

       <uslng:violation>

           <uslng:message -common attributes-

               -- constraint message --

           </uslng:message

       </uslng:violation>

       </uslng:message>

   </uslng:param>

   </uslng:message>

</uslng:messages>

This example shows a rule violation message during execution of a batch SQL task.

Attributes

Name

Mandatory

Type

Values

Source

No

string

constraint | rdbms | NULL (not present)