IBM Support

PH59503: DB2 NATIVE REST PACKAGES CONTAINS STMTNO COLUMN VALUE 0 FOR ALL ROWS IN SYSIBM.SYSPACKSTMT

A fix is available

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • For Db2 Native Rest packages, the STMTNO column always contains
    the value 0 in the SYSIBM.SYSPACKSTMT catalog table. This is
    incorrect and may cause queries to fail to extract the
    STATEMENT column when those queries depend upon STMTNO > 0.
    
    Additional Keywords:
    DB2REST DDFREST DB2DDF INCORROUT
    

Local fix

  • For Db2 Native REST packages, ignore STMTNO and use only
    SECTNO=1 to determine which SYSIBM.SYSPACKSTMT contains a valid
    STATEMENT column with the statement text.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * All Db2 12 and 13 for z/OS users of native                   *
    * RESTful services.                                            *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * Db2 native REST service packages                             *
    * contain a STMTNO column value of 0 in                        *
    * SYSIBM.SYSPACKSTMT catalog table when                        *
    * the STATEMENT column contains a valid                        *
    * SQL statement.                                               *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Apply corrective PTF when available                          *
    ****************************************************************
    During bind of the SQL statement in a native REST package, the
    statement number was set to 0. This is incorrect and may
    result in queries against SYSIBM.SYSPACKSTMT failing to
    extract the STATEMENT column when those queries depend upon
    STMTNO being non-zero.
    This issue affects native REST services created through the
    createService API and DSN BIND SERVICE subcommand.
    

Problem conclusion

  • Db2 has been changed to set the statement number to the
    section number when binding the SQL statement during
    createService and DSN BIND SERVICE.
    This APAR does not correct STMTNO of SYSIBM.SYSPACKSTMT for
    any native REST service packages that were created prior to
    applying this APAR. To correct the STMTNO for these cases,
    the REST service must be dropped and recreated after applying
    this APAR. Use the following query to identify existing REST
    service packages that have a STMTNO value of 0:
     SELECT A.COLLID, A.NAME, A.VERSION, A.STATEMENT
     FROM SYSIBM.SYSPACKSTMT A, SYSIBM.SYSPACKAGE B
     WHERE
       B.HOSTLANG='R' AND
       A.COLLID=B.COLLID AND
       A.NAME=B.NAME AND
       A.VERSION=B.VERSION AND
       A.SECTNO=1 AND
       A.STMTNO=0
    

Temporary fix

Comments

APAR Information

  • APAR number

    PH59503

  • Reported component name

    DB2 OS/390 & Z/

  • Reported component ID

    5740XYR00

  • Reported release

    D10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2024-01-30

  • Closed date

    2024-03-01

  • Last modified date

    2024-04-01

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

    UI95904 UI95905

Modules/Macros

  • DSNLJDSN DSNLJEMG DSNLJMUS
    

Fix information

  • Fixed component name

    DB2 OS/390 & Z/

  • Fixed component ID

    5740XYR00

Applicable component levels

  • RC10 PSY UI95904

       UP24/03/12 P F403

  • RD10 PSY UI95905

       UP24/03/12 P F403

Fix is available

  • Select the PTF appropriate for your component level. You will be required to sign in. Distribution on physical media is not available in all countries.

[{"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SSEPEK","label":"DB2 for z\/OS"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"D10","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
04 April 2024