Skip to Main Content
IBM Data and AI Ideas Portal for Customers


This portal is to open public enhancement requests against products and services offered by the IBM Data & AI organization. To view all of your ideas submitted to IBM, create and manage groups of Ideas, or create an idea explicitly set to be either visible by all (public) or visible only to you and IBM (private), use the IBM Unified Ideas Portal (https://ideas.ibm.com).


Shape the future of IBM!

We invite you to shape the future of IBM, including product roadmaps, by submitting ideas that matter to you the most. Here's how it works:


Search existing ideas

Start by searching and reviewing ideas and requests to enhance a product or service. Take a look at ideas others have posted, and add a comment, vote, or subscribe to updates on them if they matter to you. If you can't find what you are looking for,


Post your ideas

Post ideas and requests to enhance a product or service. Take a look at ideas others have posted and upvote them if they matter to you,

  1. Post an idea

  2. Upvote ideas that matter most to you

  3. Get feedback from the IBM team to refine your idea


Specific links you will want to bookmark for future use

Welcome to the IBM Ideas Portal (https://www.ibm.com/ideas) - Use this site to find out additional information and details about the IBM Ideas process and statuses.

IBM Unified Ideas Portal (https://ideas.ibm.com) - Use this site to view all of your ideas, create new ideas for any IBM product, or search for ideas across all of IBM.

ideasibm@us.ibm.com - Use this email to suggest enhancements to the Ideas process or request help from IBM for submitting your Ideas.

IBM Employees should enter Ideas at https://ideas.ibm.com


Status Not under consideration
Workspace Db2 for z/OS
Created by Guest
Created on Jun 13, 2017

Push up of local predicat...

In PMR 89848.077.724 you see an example that the DB2 optimizer is not able to push out local predicates that are specified in the correlated subquery to the parent query block. The predicates AND "AVADMIN"."TLORM_DBFE"."MANDANT" = ?
AND "AVADMIN"."TLORM_DBFE"."BERATER" = ? are belonging to the parent query block. The SQL syntax allows to specify them in the parent query block and also in the subquery block. The DB2 optimizer should be able to rewrite the query in an adequate way so that this predicates can be applied as early as possible. This seems to be a general problem! The execution costs are more than 10 000 times higher comparing that SQL statement to an SQL statement there the rewrite was done by the user. This SQL statement would look this way:

DELETE
FROM avadmin.VLORM_DBFE B
WHERE B.BERATER = :H
AND B.MANDANT = :H AND
EXISTS (
SELECT *
FROM avadmin.VLORM_ABRUF_STEUER J
WHERE B.BERATER = J.BERATER
AND B.MANDANT = J.MANDANT
AND B.PERSONALNUMMER = J.PERSONALNUMMER
AND B.DUE_VERFAHREN = J.DUE_VERFAHREN
AND B.RMV_TS = J.RMV_TS
AND B.LFDNUM = J.LFDNUM
AND J.PRODUKT_KUERZEL IN (
SELECT DISTINCT WERT
FROM AVADMIN.ASOFU_PRODUKT_ID
WHERE VIEWNAME = 'VLORM_ABRUF_STEUER '
AND SOFU_ID = :H ))

Today the DB2 optimizer must be able to do that rewrite under the cover!
  • Admin
    Janet Figone
    Reply
    |
    Dec 6, 2022

    Hello Norbert, The Db2 for z/OS development team in this component area re-reviewed this idea and determined the level of development and test effort is very large. They believe the need of predicate bubble up is rare in DELETE/UPDATE (we do support it in SELECT). And in those rare occasions they suggeest that you can rewrite it to parent QB. Therefore, their conclusion is 'not for consideration' for now.

    We appreciate your input and we hope that you will continue to submit enhancement suggestions for improvements as customer feedback is a key component to shaping the future direction of Db2 for z/OS.

    Sincerely,

    The Db2 for z/OS Team

  • Admin
    Janet Figone
    Reply
    |
    Jun 24, 2022

    Norbert, Thank you for providing these additional, helpful details. I have asked our engineer to review them.

  • Guest
    Reply
    |
    Jun 24, 2022

    Hello Janet,

    for the DELETE statement the rewrite was done by myself. If I analyse (via EXPLAIN) the original DELETE statement:

    DELETE

    FROM AVADMIN.ALORM_DBFE B

    WHERE EXISTS (

    SELECT *

    FROM AVADMIN.ALORM_ABRUF_STEUER J

    WHERE B.BERATER = :H

    AND B.MANDANT = :H

    AND B.BERATER = J.BERATER

    AND B.MANDANT = J.MANDANT

    AND B.PERSONALNUMMER = J.PERSONALNUMMER

    AND B.DUE_VERFAHREN = J.DUE_VERFAHREN

    AND B.RMV_TS = J.RMV_TS

    AND B.LFDNUM = J.LFDNUM

    AND J.PRODUKT_KUERZEL IN (

    SELECT DISTINCT WERT

    FROM AVADMIN.ASOFU_PRODUKT_ID

    WHERE VIEWNAME = 'VLORM_ABRUF_STEUER '

    AND SOFU_ID = :H ) )


    the automatic rewrite is not done in v12. This only works for SELECT syntax - so I can't see that the functionalty is delivered


    kind regards

    Norbert Wolf

    Datev eG


  • Admin
    Janet Figone
    Reply
    |
    Jun 23, 2022

    Hello Norbert, After further investigation it has been determined that support for this was delivered in 2014, with additional enhancements delivered in 2016. As such, this idea is closed as Delivered.

    We appreciate your input to the Db2 for z/OS development team. And we hope that you will continue to submit enhancement suggestions for improvements as customer feedback is a key component to shaping the future direction of Db2 for z/OS.

    Sincerely,

    The Db2 for z/OS Team

  • Guest
    Reply
    |
    May 24, 2021

    Should be investigated by QST.

    On a first look, this type of predicate bubble up should be supported in earlier releases (prior to V12).