IBM Data and AI Ideas Portal for Customers


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:

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

Help IBM prioritize your ideas and requests

The IBM team may need your help to refine the ideas so they may ask for more information or feedback. The product management team will then decide if they can begin working on your idea. If they can start during the next development cycle, they will put the idea on the priority list. Each team at IBM works on a different schedule, where some ideas can be implemented right away, others may be placed on a different schedule.

Receive notification on the decision

Some ideas can be implemented at IBM, while others may not fit within the development plans for the product. In either case, the team will let you know as soon as possible. In some cases, we may be able to find alternatives for ideas which cannot be implemented in a reasonable time.

Additional Information

To view our roadmaps: http://ibm.biz/Data-and-AI-Roadmaps

Reminder: This is not the place to submit defects or support needs, please use normal support channel for these cases

IBM Employees:

The correct URL for entering your ideas is: https://hybridcloudunit-internal.ideas.aha.io


Status Not under consideration
Workspace Db2 Warehouse
Created by Guest
Created on Jul 15, 2019

Enable UDTF parallelization

[REGRESSION FROM NETEZZA]

By default, a UDTF written in CPP is registered in DISALLOW PARALLEL mode using the IDA DEPLOYUDX command. As a result, the UDTF is invoked on a single partition only on an MPP system. This is a serious performance bottleneck for any unit of work involving a UDTF. There is no setting to change this behavior. While this may be an enhancement for Db2, it is a serious regression for all applications and customers migrating from Netezza. Please accept and expedite ALLOW PARALLEL for UDTF written in CPP.

--- Example invocation ---
SELECT a.*
FROM (
SELECT a.GroupID AS GroupID, a.val_ID as pValID,
a.val_type as pValType, a.num_val as pNumVal,
NVL(LAG(0) OVER (PARTITION BY a.GroupID order by val_type), 1) AS Begin_flag,
NVL(LEAD(0) OVER (PARTITION BY a.GroupID order by val_type), 1) AS End_flag
FROM tblBSplineBasisTestMD a
) AS z,
TABLE (FLBSplineBasisUdt(z.GroupID, z.pValType, z.pNumVal, 3,
z.Begin_Flag,
z.End_Flag,
z.pValID)) AS a
ORDER BY 1, 2, 3 ;

--- Engineering notes from IBM ---
1. Db2 does not guarantee partition function invocation association and neither guarantees the 'order by' of the sub-query be honored for the table function invocation. The expert's opinion is if we see such behavior sometimes, it is plain luck and we should not rely on such behavior in our design.
2. All records of a partition should go to a single instance of the UDTF.
3. The records within the partition should be passed in the same order to the UDTF as given in the order by clause of the partition.
4. Currently, the above cannot be enforced and optimizer experts say parallel processing could destroy the order in which the subquery feeds the UDTF. No rewrites are available to make it work.
5. Further, the reason we get the partition records in order currently is because lead/lag functions used in the FL query are not pushed down to CDE. As a result, the correlation b/w the subquery and UDTF happens via a row TQ which maintains the order. However, if lead/lag functions get pushed down to CDE, the optimizer team believes this behavior may change. Also the optimizer team will not document this behavior as it is not mandated by SQL standard. In the long term, we have to explore other options considering this behavior could change and also solve the problem of UDTF logic running only on one node.
6. If this feature is accepted as an enhancement, FL advises to implement in a different (more appropriate) way – by adding a PARTITION BY and LOCAL ORDER BY clauses to the UDT invocation itself (not through a sub-query).