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 Functionality already exists
Workspace IBM i
Categories Db2 for i
Created by Guest
Created on May 12, 2025

Point SQL messages to the place where they originated

When we see a message in the log like SQL0501 - Cursor xxx not open, and drill down to the details to find where the message comes from we see internal SQL references and not our program name and statement.

This makes it hard to debug and fix.

Please provide the program and statement where the issue originated,
 

```
                            Display Message Details                            
                                                                              
Message ID . . . . . . :   SQL0501       Severity . . . . . . . :   30        
Date sent  . . . . . . :   12-05-25      Time sent  . . . . . . :   10:40:00  
Message type . . . . . :   Diagnostic                                         
From . . . . . . . . . :   OMSIUNIT      CCSID  . . . . . . . . :   65535     
                                                                              
From program . . . . . . . . . :   QSQRUN4                                    <----- NOT MY PROGRAM
  From library . . . . . . . . :     QSYS                                     
  From module  . . . . . . . . :     QSQCLS                                   
  From procedure . . . . . . . :     CLEANUP                                  
  From statement . . . . . . . :     6355                                     
                                                                              
To program . . . . . . . . . . :   QSQRUN4                                    
  To library . . . . . . . . . :     QSYS                                     
  To module  . . . . . . . . . :     QSQCLS                                   
  To procedure . . . . . . . . :     CLEANUP                                  
  To statement . . . . . . . . :     6355                                     
```

Idea priority Low
  • Guest
    May 20, 2025

    Thanks for the feedback. However, it is not a convenient solution.  Send by and received by QSQRUN4 does not really help pinning down the issue and then having to start another tool to get specifics is not very effective. 

  • Guest
    May 20, 2025
    IBM believes that a solution for the Idea described is available through the use of SELF (SQL Error Logging Facility).

    The messages in the joblog indicate the program that issued the error. This is how the system message handling facility works. SQL cannot modify the program listed in these messages.

    SQL provides a solution that is a good fit to understand your error situation. SELF was introduced in 2022 for IBM i 7.4 and later releases. With SELF, you can register SQL error or warning SQLCODEs that should be logged. When a job encounters the SQLCODE during its SQL processing, the error details and environmental information about the error are recorded. This includes the full call stack at the time the error occurred.

    For your situation, turn SELF on for either the specific -501 error or use the *ERROR value to log all errors. Then run your program and the information will be captured for you. After the error is encountered, review the log file to see the complete details for the error.

    See this page for information and links to the IBM Documentation pages.
    https://www.ibm.com/support/pages/node/6828091

    Db2 for i development team
    IBM Power Systems Development