PM46977: INCORROUT OF AN SQL VARIABLE IN A NATIVE SQL PROCEDURE DUE TO A MEMORY OVERLAY

A fix is available

Subscribe

You can track all active APARs for this component.

APAR status

  • Closed as program error.

Error description

  • INCORROUT of an SQL VARIABLE in a native SQL procedure
    due to a storage overlay .
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED: All DB2 9 for z/OS and DB2 10 for z/OS       *
    *                 users of native SQL procedures.              *
    ****************************************************************
    * PROBLEM DESCRIPTION: A one byte overlay can occur while      *
    *                      assigning a nullable char column to a   *
    *                      nullable char SQL variable if the       *
    *                      source length is longer than the target *
    *                      length.                                 *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    A one byte overlay can occur while assigning a nullable char
    column to a nullable char SQL variable if the source length
    is longer than the target length.
    
    The following example illustrates the problem.
    
    STEP 1.
    
    In a native SQL procedure, make the following simple variable
    
    declarations.
    
      DECLARE V1  CHAR(10);
      DECLARE V2  CHAR(09);
      DECLARE V3  SMALLINT;
    
    
    STEP 2.
    
    Perform the following query to select into these variables.
    
       SELECT  P.QTY, P.V_TXT, P.V_TXT
       INTO V3, V2, V1
       FROM PER P;
    
    Please note:  V_TXT  is defined as CHAR(30) NULLABLE.
                  V1 and V2 are CHAR(10) and CHAR(9) NULLABLE.
                  V3 is SMALLINT.
    
    STEP 3.
    
    The overlay can cause an incorrect result to be returned from
    this query.
    

Problem conclusion

  • The code in DB2 runtime has been modified to correct the one
    byte overlay.
    
    Additional Keywords: SQLNATIVESQLPL SQLINCORR INCORROUT
                         SQLINCORROUT  DB2INCORR/K SMCOVERLAY
                         DB2OVRLAY/K
    

Temporary fix

  • *********
    * HIPER *
    *********
    

Comments

APAR Information

  • APAR number

    PM46977

  • Reported component name

    DB2 OS/390 & Z/

  • Reported component ID

    5740XYR00

  • Reported release

    910

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    YesHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2011-09-01

  • Closed date

    2011-11-01

  • Last modified date

    2011-12-02

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

    UK73434 UK73435

Modules/Macros

  •    DSNXRBND DSNXRBN9 DSNXRPO9 DSNXRRP  DSNXRRPO
    DSNXRRP9
    

Fix information

  • Fixed component name

    DB2 OS/390 & Z/

  • Fixed component ID

    5740XYR00

Applicable component levels

  • RA10 PSY UK73434

       UP11/11/18 P F111

  • R910 PSY UK73435

       UP11/11/18 P F111

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.



Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

DB2 for z/OS

Software version:

910

Reference #:

PM46977

Modified date:

2011-12-02

Translate my page

Machine Translation

Content navigation