Detail View 2007

Datum

23.11.2007

 

Keywords

Side effect from the Communication Database (CDB) column definition changes in DB2 for z/OS V8

up
davor
weiter

DB2 ist ein Produkt der
IBM Corporation. Bitte
Copyright-  und Trademark-Hinweise beachten!


http://www-1.ibm.com/support/docview.wss?rs=865&context=SSEPEK&dc=DB510&dc=DB520&dc=D800&dc=D900&dc=DA900&dc=DA800&dc=DA440&dc=D600&dc=D700& dc=DB540&dc=DB400&dc=DA410&dc=DA450&dc=DA430&uid=swg21245179&loc=en_US&cs=UTF-8&lang=all

Problem
SQLCODE904 or -904 with RC00D31030

Cause
During migration to DB2 V8 NFM (new-function Mode) the DDF Communications Database (CDB) is converted to Unicode. To cover all special characters (especially the special signs in some countries) some of the column data types have been changed from fixed CHAR(8) character fields to VARCHAR(24).
But this change to VARCHAR has an impact:
Previously all CHAR columns were handled according to their defined length.
For example, for CHAR(8) columns, the contents were blank-padded or trimmed to achieve their length of 8. With the new VARCHAR definition, no blank-padding or trimming is done. Therefore the CDB administrator must ensure that values for columns in the CDB, such as LINKNAME, LUNAME, and so forth, contain the correct number of bytes and trailing blanks.

For example:
INSERT INTO SYSIBM.LULIST( LINKNAME ,LUNAME ,IBMREQD ) VALUES ( 'XXXXX' ,'XXXXXXXbb' ,'N' ) with "X" as a valid alpanumeric character and "b" as a blank.

In a DB2 for OS/390 and z/OS V7 system, the actual value stored for LINKNAME would be 'XXXXXbb' because of the fixed CHAR(8) data type definition. Similarly, the actual value stored for the LUNAME would be 'XXXXXXXb'. However, in a DB2 for z/OS V8 system, both the LINKNAME and LUNAME columns are defined as VARCHAR(24). Thus, the LINKNAME will contain 'XXXXX' as it is provided on input (no blanks padded at the end) and the LUNAME will contain 'XXXXXXXbb' (last blank is not trimmed) as it is provided on input. In this case, the LUNAME becomes an invalid LUNAME because an LUNAME value can contain up to 8 bytes. When this LUNAME is being used, DB2 for z/OS issues an error reason code of '00D31030'X.
Please refer also to APAR PK20076 (and also PK25104)

Solution
Be sensitive to missing or addtional blanks for column values in the DB2 CDB



P.S. Please pass my address to anyone interested in DB2 HOTLINE - thank you.

With kind regards
Michael Dewert, Software Group
DB2 Development
DB2 Information Management Software

© Gernot Ruban