DSTransformError

Use the DSTransformerError function to log a warning message to a job log file. This function is called from transforms only.

Syntax


Call DSTransformError (Message, TransformName)

Message (input) is the warning message you want to log. Message is automatically prefixed with the name of the current stage and the calling transform.

TransformName (input) is the name of the transform that calls the DSTransformError subroutine.

Remarks

DSTransformError writes the message (and other information) to the job log file as a warning and returns to the transform. If the job has a warning limit defined for it, when the number of warnings reaches that limit, the call does not return and the job is aborted.

In addition to the warning message, DSTransformError logs the values of all columns in the current rows for all input and output links connected to the current stage.

Example


Function MySqrt(Arg1)
If Arg1 < 0 Then
   Call DSTransformError("Negative value:"Arg1, "MySqrt")
   Return("0")    ;*transform produces 0 in this case
End
   Result = Sqrt(Arg1) ;* else return the square root
Return(Result)