Error - Throw an Error in Informatica

The ERROR function causes the Informatica Server to skip a record and throws an
error message defined by the user.
ERROR( string )

Example : Error Handling to code to omit negative values
IIF( SALARY < 0, ERROR ('Error. Negative salary found. Row skipped.'), EMP_SALARY )

Salary             Return value
 10000            10000
-15000            'Error. Negative salary found. Row skipped.'

Error function is used together with test function and it throws an error when the test condition is not satisfied.

Error message will be displayed in session log.

Note :
When you use output default value other than ERROR, the default value overrides the ERROR function in an expression.

For eg., you use the ERROR function in an expression, and you assign the default value, ‘1234’, to the output port. Each time the Integration Service encounters the ERROR function in the expression, it overrides the error with the value ‘1234’ and passes ‘1234’ to the next transformation. It does not skip the row, and it does not log an error in the session log.