Skip to Main Content
IBM Power Ideas Portal


This portal is to open public enhancement requests against IBM Power Systems products, including IBM i. 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
  1. Post an idea.

  2. Get feedback from the IBM team and other customers to refine your idea.

  3. Follow the idea through the IBM Ideas process.


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.

Status Future consideration
Workspace IBM i
Categories Db2 for i
Created by Guest
Created on Sep 1, 2022
Merged idea
This idea has been merged into another idea. To comment or vote on this idea, please visit IBMI-I-3383 Enhanced SQL Call Level Interface (CLI) resource management options.

Enhanced memory management option for SQL Call Level Interface (CLI) Merged

Today, a CLI (SQL Call Level Interface) environment handle allocated via the SQLAllocEnv() API is automatically tied to the callstack entry which allocated it, meaning that when that program leaves the stack, the system deems the environment handle fair game for automatic cleanup. What we're looking for is an override switch to this functionality, where a CLI environment handle (and all associated resources) can optionally be 'flagged' as being managed by the caller, rather than by the system (perhaps SQL_HANDLE_MANAGEMENT_AUTO/CALLER; default AUTO). Really any method to prevent this automatic cleanup of environment/connection resources will do - the setting of a system environment variable or whatever, we don't mind. The point here is, the CLI suite of APIs is excellent, and we - and I suspect others as well - would like to be able to do more with it. The value of any good API is that it crystallises a specific function such that it can be re-used more easily. Iteratively re-using established APIs / BIFs to build additional layers of programming tools is how we keep evolving our coding practices and the complexity/flexibility of our coded solutions. What this memory management limitation of the CLI effectively does is prevent the allocation of key resource handles in certain containerized functional blocks - specifically procedures exported from a service program. If a (RPG) service program were to be developed offering helper APIs for xConnect(), xQuery(), xRead(), etc., the inner workings of these functions could (for example) automatically describe the dynamic result sets, allocate and bind buffers, perform blocked fetches, protecting the calling program from the relative complexity required. If the CLI cannot support resources being instantiated from atomic, exported service program procedures in this way, however, (because the service program in this case only briefly remains on the call stack), then such a toolset becomes seemingly impossible to realise with CLI. In my view this criminally restricts the usefulness of the CLI, which would otherwise offer the most powerful SQL interface (for DB2i connections) on the iSeries platform. I suspect this limitation is borne out of good intentions, rather than willfull restriction of the tool. But early issues with memory management in the original incarnations of the CLI are a distant memory by this point, and I think the time has come to allow these handles to be explicitly managed by the application programmer in certain circumstances. What do you think?
Idea priority Low
  • Guest
    Reply
    |
    Sep 8, 2022
    This request is an accidental duplicate of IBM Idea IBMI-I-3383. Marking it that way since there is no way to remove it.

    Db2 for i development team
    IBM Power Systems Development
  • Guest
    Reply
    |
    Sep 8, 2022

    **This is a DUPLICATE of IBMI-I-3383, but I don't know how to remove it...**