DB2 Version 9.7 for Linux, UNIX, and Windows

FP1: User-defined functions support OUT and INOUT parameters

In Version 9.7 Fix Pack 1 and later fix packs, you can define external C user-defined functions (UDFs) as well as SQL PL and PL/SQL user-defined functions with OUT and INOUT parameters.

This support enables functions to return results not only through the RETURN statement but also by setting output parameters. Functions can return status information in addition to their regular results.

You can use functions with OUT or INOUT parameters as the sole expression on the right side of an assignment statement.