IBM Support

IT19590: DB2 MIGHT PRODUCE A SQL0901N, EXECUTING QUERIES WITH UNION ALL

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • In rare scenarios, DB2 might produce a SQL0901N when the
    following is true at Optimized SQL:
    
    1) The query contains one or more UNION ALL clauses
    2) The query contains a DISTINCT or an existential subquery
       of the form IN/EXISTS
    
    Here is an example stack trace:
    -----
       :
    sqlnn_erds
    destroy
    destroy
    sqlnq_union_ofn_sm
    sqlnq_union_ofn_sm
    sqlnq_viewsel_ofn_sm
    sqlnq_proc_enc
    add_doid
    sqlnq_sel_doid
    sqlnq_select_ofn_sm
    sqlnq_proc_enc
    sqlnq_union_ofn_sm
    sqlnq_viewsel_ofn_sm
    sqlnq_proc_enc
    add_doid
    sqlnr_addids
    sqlnr_joinppd_action
       :
    -----
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * all                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * See Error Description                                        *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to db2_v111m4fp6 or later                            *
    ****************************************************************
    

Problem conclusion

  • Upgrade to db2_v111m4fp6 or later
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT19590

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    A50

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2017-03-08

  • Closed date

    2021-01-14

  • Last modified date

    2021-01-14

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

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

    IT39274

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":"10.5","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
04 May 2022