Variable assignment: If the specified variable is character and is not large enough to contain the result, a warning (SQLSTATE 01004) is returned (and 'W' is assigned to SQLWARN1 in the SQLCA). The actual length of the result is returned in the indicator variable associated with the variable, if an indicator variable is provided.
If the specified variable is a C NUL-terminated variable and is not large enough to contain the result and the NUL-terminator:
Multiple assignments: If more than one assignment is included in the same SET statement, all expressions and row-fullselects are completely evaluated before the assignments are performed. Thus, references to a target variable in an expression or row-fullselect are always the value of the target variable prior to any assignment in the SET statement.
(C) Copyright IBM Corporation 1992, 2006. All Rights Reserved.