Using components: Assert

Use the Assert component to make sure that all data in the source complies with the conditions you specify in the component. If a record does not comply, the job fails and a message is added to the error log.

To set the assert conditions:
  1. Add an Assert component where required in your package.
  2. Open the component and name it.
  3. Under settings, in the assertion message text box, type the alert message that will appear if a record is blocked by the conditions (that you will specify below) as follows:
  4. Under conditions, indicate how the filter should apply the conditions (that you will specify below) as follows:
    • all - selects records with values that meet all conditions specified (logical "AND")
    • any - selects records with values that meet any of the conditions specified (logical "OR")
    • none - selects records that don't meet all the conditions specified (logical "NOT AND")
  5. Specify a condition as follows:
    1. In the first drop-down list, select the field whose values you wish to filter. You can use functions in the field column to manipulate field data (see Using functions in components).
    2. In the second drop-down list, select the operator as follows:
      Operator Description
      text equals The expression on the left must be equal to the string value on the right. The text should not be enclosed in quotes or escaped.
      text not equals The expression on the left must not be equal to the string value on the right. The text should not be enclosed in quotes or escaped.
      text matches The expression on the left must must match the regular expression string value on the right. The text should not be enclosed in quotes or escaped. For example, matching a string field with .*dog.* would pass any string that contains the string dog: dog,dogs,adogmatic
      text is empty The expression on the left must be empty.
      text is not empty The expression on the left must not be empty.
      = The expression on the left must be equal to the expression on the right.
      != The expression on the left must not be equal to the expression on the right.
      > The expression on the left must be greater than the expression on the right.
      >= The expression on the left must be greater than or equal to the expression on the right.
      < The expression on the left must be less than the expression on the right.
      <= The expression on the left must be less than or equal to the expression on the right.
      is null The expression on the left must be null.
      is not null The expression on the left must not be null.
      is true The expression on the left must true - especially useful when left hand side is a complex expression.
    3. In the last text box, type the value that the condition will filter for.
  6. Add additional conditions as required.
  7. You can nest a condition by pressing Shift while hovering on the blue + icon that appears at the right of an existing condition until the icon changes to a blue right arrow.

Feedback and Knowledge Base