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 (

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 ( - Use this site to find out additional information and details about the IBM Ideas process and statuses.

IBM Unified Ideas Portal ( - Use this site to view all of your ideas, create new ideas for any IBM product, or search for ideas across all of IBM. - Use this email to suggest enhancements to the Ideas process or request help from IBM for submitting your Ideas.

IBM Data & AI Roadmaps ( - Use this site to view roadmaps for Data & AI products.

IBM Employees should enter Ideas at

Status Future consideration
Workspace Db2
Created by Guest
Created on Aug 12, 2021

Allow DB2 connection to be inherited by a subshell

With the db2 command it is possible to execute a wide variety of DB2 tasks from a shell environment. It is however not possible to use variable substitution in a way that feels natural in a Unix environment. The execution of a shell script starts without the existing connection since it it is not inherited by a subshell. It is necessary to either source the script or create a file with the SQL to be executed. There is also no feature to use variable substition in files containig sql.

This restriction is a pain point in my life as a developer, since it is extremely difficult to develop a toolset for my everyday tasks. As a simple example I would like to create a script <dbname> that lists the objects of a given database without supplying credentials that create a new connection although in the current shell it alredy exists.

Needed By Yesterday (Let's go already!)
  • Guest
    Oct 5, 2021

    Current design of the clp is that a backend process(db2bp) gets created in a new shell which serves to the front end process(db2) that fires the db2 commands in the new shell. These clp processes in the new shell are completely different from the clp processes in parent shell. Hence it can't inherit the connection from parent shell to the new shell.

    Request you to use one of the below options which you may already know

    1) Execute the script in the current shell itself(using . operator) as shown below instead of using a new shell

    . ./

    2) Use new shell to execute the script like below, but establish a connection in the shell script and then call the sql file.

    ./ dbname userid passwd

    Content of could be

    db2 connect to SAMPLE user $1 using $2

    db2 -vf test.sql

    Content of test.sql could be

    select * from mytab1