IBM Support

IT30249: WRONG RESULTS ARE POSSIBLE FOR FEDERATED OR COLUMNAR QUERY WITH AGGREGATION OVER DISTINCT OUTER JOIN

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

 

APAR status

  • Closed as program error.

Error description

  • WRONG RESULTS ARE POSSIBLE FOR FEDERATED OR COLUMNAR QUERY WITH
    AGGREGATION OVER DISTINCT OUTER JOIN
    The following query yields wrong results if the source tables
    are either federated nicknames or column-organized tables.
    
    with v(a, b) as
     (select distinct t1.c2, t2.c1 from t1 left join t2 on
    t1.c1=t2.c2)
    select sum(b) as sumofb, a from v group by a
    ;
    
    e.g. say t1 contains rows (1, 1), (1, 2) and t2 contains rows
    (1, 1), (2, 1), (2, 1)
    
    If t1 and t2 are nicknames or if t1 and t2 are column-organized
    tables this incorrectly returns:
    SUMOFB      A
    ----------- -----------
              5           2
              5           1
    
      2 record(s) selected.
    
    But the correct result is this:
    SUMOFB      A
    ----------- -----------
              3           1
              3           2
    
      2 record(s) selected.
    
    This problem is specific to Outer Join.
    

Local fix

  • N/A
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * ALL                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * See Error Description                                        *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to Db2 11.1 Mod 4 Fixpack 5 or higher                *
    ****************************************************************
    

Problem conclusion

  • First fixed in Db2 11.1 Mod 4 Fixpack 5
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT30249

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    B10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    YesHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2019-09-11

  • Closed date

    2020-01-16

  • Last modified date

    2020-01-16

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

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

    IT30251 IT30252

Fix information

  • Fixed component name

    DB2 FOR LUW

  • Fixed component ID

    DB2FORLUW

Applicable component levels

[{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSEPGG","label":"Db2 for Linux, UNIX and Windows"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"11.1","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
16 January 2020