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 Future consideration
Created by Guest
Created on Jun 8, 2023

Format the SQL statement under TSO/ISPF

Db2 Query Monitor has 2 interfaces, TSO/ISPF and Consolidation and Analysis Engine(CAE). Under the CAE, also known as the Web Client, the SQL statement being displayed is formatted. However, this is not the case for TSO. Here’s an example:

DECLARE C_TRIG3 CURSOR

WITH HOLD FOR SELECT T4 . *

FROM SYSTRIGGERS T4 , SYSPACKDEP T5 , SYSTRIGGERS T1 , SYSPACKDEP T2 , SESSION . ADBGEN T3

WHERE T1 . NAME = T2 . DNAME AND T1 . SCHEMA = T2 . DCOLLID AND ( T1 . SEQNO = 1 OR T1 . SEQNO = 0 ) AND T2 . DLOCATION =

' ' AND T2 . BQUALIFIER = T3 . CREATOR AND T2 . BNAME = T3 . NAME AND T2 . BTYPE = 'T' AND ( T3 . TYPE = 'TB'

OR T3 . TYPE = : H ) AND T1 . NAME = T5 . DNAME AND T1 . SCHEMA = T5 . DCOLLID AND ( T4 . SEQNO = 1 OR T4 . SEQNO = 0 ) AND

T5 . DLOCATION = ' ' AND T5 . DTYPE = 'T' AND T5 . BQUALIFIER = T4 . TBOWNER AND T5 . BNAME = T4 . TBNAME AND

T5 . BTYPE = 'T' ORDER BY CREATEDTS , SCHEMA , NAME

There is a Db2 stored procedure that could be called to format the SQL statement (ADB2FMP):
https://www.ibm.com/docs/en/db2admintool/13.1?topic=apis-adb2fmp-stored-procedure
Today, I might cut and paste the query into another tool, such as QMF for Workstation, to format the query. Small queries are not bad. But when you have an SQL statement the spans multiple pages, an unformatted query gets difficult to try and understand what it’s doing.
When the SQL statement is EXP (exported) from Db2 Query Monitor, also write the query in the formatted option.
Needed By Not sure -- Just thought it was cool
  • Guest
    Reply
    |
    Dec 19, 2023

    Agreed this is cumbersome/painful at times especially when working with larger queries and trying to get their format up to speed after being exported

6 MERGED

Remove Spaces Between Qualifier and Column Name

Merged
CQM displays SQL such as this:SELECT A . ACCOUNT_ID INTO : H FROM EA_AFLT_X_PRDCT A , EA_PRDCT B WHERE A . AFLT_ID = : H AND A . ACCOUNT_ID BETWEEN : H AND : H AND A . ACCOUNT_ID = B . ACCOUNT_ID AND A . BU_CD = B . BU_CD AND A . PRDCT_STAT_NM...
7 months ago in Db2 Query Monitor for z/OS 1 Future consideration