A fix is available
APAR status
Closed as program error.
Error description
A logical unload specifying an expression with the MOD() scalar function either unloads incorrect data or unduly reports and incorrect use of the MOD() function by issuing the INZU025E message. The symptoms and scope of the issue are detailed below. The following cases exhibit the set of symptoms detailed below: Case 1: - the message INZU025E INVALID OPERAND FOR MOD() is unduly issued - the related unload is thus unduly considered as unsupported in native mode as reported by the message INZU063I UNSUPPORTED SELECT (UNHANDLED OR NOT COMPLIANT SELECT STATEMENT) and processed accordingly (depending on the switch to SQL mode being allowed) Case 2: - either the INZU447E or INZU447W error message is issued and mentions that AN ERROR OCCURRED DURING UNLOAD PROCESSING - REFER TO PREVIOUS EXPLANATION MESSAGES referring to the following root cause * 227 * EXPRESSION EVALUATION ERROR * ddname * column_number - unloaded rows are not the correct ones Case 3: - unloaded rows are not the correct ones The symptoms described above occur if all the following conditions are fulfilled: - either DB2 NO or DB2 YES applies - a SELECT statement is specified that: - is eligible for native processing - contains an SQL expression that uses the MOD(bigint_expression, (small)int_expression) scalar function where bigint_expression is an expression of BIGINT data type and (small)int_expression is an expression of either SMALLINT or INT data type is specified - at least one of the following conditions below related to the issue cases mentioned above is met: - Case 1: the bigint_expression is a trivial BIGINT constant - For cases 2 and 3 all the common following conditions are met: - bigint_expression is not a trivial BIGINT constant - for some rows to unload, bigint_expression < -2 147 483 648 or bigint_expression > 2 147 483 647 - The following case-dependent condition applies for cases 2 and 3: - Case 2: the MOD(bigint_expression,int_expression) is specified in the selected item - Case 3: the MOD(bigint_expression,int_expression) is specified in the WHERE clause of a SELECT statement Root cause: The processing of MOD(bigint_expression,(small)int_expression) requires to handle both operands as BIGINT data. The issues described above occur because Db2 HPU unduly handles both operands as (SMALL)INT (same type as the second operand) by casting the bigint_expression (first operand) to the (SMALL)INT data type. Note: This casting error will not occur if the second operand is a bigint_expression.
Local fix
- Run Db2 HPU in SQL mode by specifying DB2 FORCE. - If keeping the native mode processing is crucial, consider casting the (small)int_expression to a bigint_expression, typically by using the BIGINT scalar function as follows (i.e. replace "(small)int_expression" with "BIGINT((small)int_expression)").
Problem summary
**************************************************************** * USERS AFFECTED: Users of Db2 High Performance Unload for * * z/OS * **************************************************************** * PROBLEM DESCRIPTION: A logical unload specifying an * * expression with the MOD() scalar * * function either unloads incorrect data * * or unduly reports and incorrect use of * * the MOD() function by issuing the * * INZU025E message. The symptoms and * * scope of the issue are detailed below. * * * * The following cases exhibit the set of * * symptoms detailed below: * * * * Case 1: * * - the message INZU025E INVALID OPERAND * * FOR MOD() is unduly issued * * - the related unload is thus unduly * * considered as unsupported in native * * mode as reported by the message * * INZU063I UNSUPPORTED SELECT * * (UNHANDLED OR NOT COMPLIANT SELECT * * STATEMENT) and processed accordingly * * (depending on the switch to SQL mode * * being allowed) * * * * Case 2: * * - either the INZU447E or INZU447W error * * message is issued and mentions that * * AN ERROR OCCURRED DURING UNLOAD * * PROCESSING - REFER TO PREVIOUS * * EXPLANATION MESSAGES referring to the * * following root cause * 227 * * * EXPRESSION EVALUATION ERROR * * * ddname * column_number * * - unloaded rows are not the correct * * ones * * * * Case 3: * * - unloaded rows are not the correct * * ones * * * * The symptoms described above occur if * * all the following conditions are * * fulfilled: * * - either DB2 NO or DB2 YES applies * * - a SELECT statement is specified that: * * - is eligible for native processing * * - contains an SQL expression that * * uses the MOD(bigint_expression, * * (small)int_expression) scalar * * function where bigint_expression * * is an expression of BIGINT data * * type and (small)int_expression is * * an expression of either SMALLINT * * or INT data type is specified * * - at least one of the following * * conditions below related to the * * issue cases mentioned above is met: * * - Case 1: the bigint_expression is * * a trivial BIGINT constant * * - For cases 2 and 3 all the common * * following conditions are met: * * - bigint_expression is not a * * trivial BIGINT constant * * - for some rows to unload, * * bigint_expression < -2 147 * * 483 648 or bigint_expression * * > 2 147 483 647 * * - The following case-dependent * * condition applies for cases 2 and * * 3: * * - Case 2: the * * MOD(bigint_expression,int_expression) * * is specified in the selected * * item * * - Case 3: the * * MOD(bigint_expression,int_expression) * * is specified in the WHERE * * clause of a SELECT statement * * * * Root cause: * * The processing of * * MOD(bigint_expression, * * (small)int_expression) * * requires to handle both operands as * * BIGINT data. The issues described * * above occur because Db2 HPU unduly * * handles both operands as (SMALL)INT * * (same type as the second operand) by * * casting the bigint_expression (first * * operand) to the (SMALL)INT data type. * * Note: This casting error will not occur * * if the second operand is a * * bigint_expression. * * * * Local fix: * * - Run Db2 HPU in SQL mode by specifying * * DB2 FORCE. * * - If keeping the native mode processing * * is crucial, consider casting the * * (small)int_expression to a * * bigint_expression, typically by using * * the BIGINT scalar function as follows * * (i.e. replace "(small)int_expression" * * with * * "BIGINT((small)int_expression)"). * **************************************************************** * RECOMMENDATION: Apply the PTF * **************************************************************** Incorrect unloaded data and INZU447E/INZU447W or undue INZU025E for unload involving MOD(bigint_expression,(small)int_expression) scalar function
Problem conclusion
Code has been changed to fix this problem
Temporary fix
Comments
APAR Information
APAR number
PH69319
Reported component name
DB2 HI PERF UNL
Reported component ID
5697F4400
Reported release
520
Status
CLOSED PER
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt / Xsystem
Submitted date
2025-12-09
Closed date
2026-01-28
Last modified date
2026-02-01
APAR is sysrouted FROM one or more of the following:
APAR is sysrouted TO one or more of the following:
Modules/Macros
INZUTILD INZUTILK
Fix information
Fixed component name
DB2 HI PERF UNL
Fixed component ID
5697F4400
Applicable component levels
Fix is available
Select the PTF appropriate for your component level. You will be required to sign in. Distribution on physical media is not available in all countries.
[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSZJXP","label":"DB2 Tools for z\/OS"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"520","Line of Business":{"code":"LOB10","label":"Data and AI"}}]
Document Information
Modified date:
01 February 2026