IBM Support

IT38439: DB2 QUERY MAY ABEND OR RETURN A SQL 901 WHEN USING A CORRELATED COMMON TABLE EXPRESSION

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • A Db2 query may abend or generate a SQL 901 error
    when the following conditions are met:
    
    There is a correlated scalar subquery present
    There are multiple references of the above mentioned subquery
    There is one or more joins in the query.
    

Local fix

  • It may be possible to work around this by adding the Optimizer
    Guideline below to the end of the query.
    
    /* <OPTGUIDELINES>
    
       <QRYOPT VALUE='1'/>
    
    </OPTGUIDELINES> */
    
    Note:  To enable Db2 to use the optimizer guidelines it will be
    necessary to run the command db2set -im DB2_OPTPROFILE=YES.  The
    command will take effect immediately without restarting Db2
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * ALL                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * See Error Description                                        *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to Db2 Version 11.1 Fix Pack 7                       *
    ****************************************************************
    

Problem conclusion

  • First Fixed in Db2 Version 11.1 Fix Pack 7
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT38439

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    B10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2021-09-21

  • Closed date

    2022-04-17

  • Last modified date

    2022-04-17

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

    IT37889

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

Fix information

  • Fixed component name

    DB2 FOR LUW

  • Fixed component ID

    DB2FORLUW

Applicable component levels

  • RB10 PSN

       UP

[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSEPGG","label":"DB2 for Linux- UNIX and Windows"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"11.1","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
03 May 2022