IBM Support

PH49713: DB2 ADMIN TOOL: NEXTVAL IS WRAPPED IN QUOTES WHEN GENERATING DDLFOR A TRIGGER CAUSING A -206 ERROR

A fix is available

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • When generating DDL for a table with a trigger on that table,
    the value of NEXTVAL in SEQUENCE.NEXTVAL is wrapped in quotes.
    This is happening because the product assumes that NEXTVAL is a
    column name and not a reserved word. This results in a -206
    error when a generated DDL is executed.
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED: Users of Db2 Administration Tool for z/OS    *
    *                 who use the GEN function to generate DDL     *
    ****************************************************************
    * PROBLEM DESCRIPTION: When running the GEN line command on an *
    *                      object that references a sequence using *
    *                      the SEQUENCE.NEXTVAL or                 *
    *                      SCHEMA.SEQUENCE.NEXTVAL format,         *
    *                      the resulting DDL contains quotation    *
    *                      marks around the word NEXTVAL. This DDL *
    *                      will result in SQL code -206.           *
    ****************************************************************
    The SEQUENCE.NEXTVAL/CURRVAL and SCHEMA.SEQUENCE.NEXTVAL/CURRVAL
    formats were not recognized. Therefore, GEN assumed that
    'NEXTVAL' was a column on table 'SEQUENCE' and wrapped 'NEXTVAL'
    in quotation marks when generating the DDL.
    
    Keywords: GEN, TRIGGER, NEXTVAL, CURRVAL, SEQUENCE, SQLCODEN206
    

Problem conclusion

  • The problem has been resolved.
    

Temporary fix

Comments

APAR Information

  • APAR number

    PH49713

  • Reported component name

    DB2 ADMIN TOOL

  • Reported component ID

    568851500

  • Reported release

    C10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2022-09-21

  • Closed date

    2023-01-20

  • Last modified date

    2023-02-01

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

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

    UI90179 UI90180

Modules/Macros

  • ADB2PA
    

Fix information

  • Fixed component name

    DB2 ADMIN TOOL

  • Fixed component ID

    568851500

Applicable component levels

  • RC10 PSY UI90179

       UP23/02/01 P F301

  • RD10 PSY UI90180

       UP23/02/01 P F301

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":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSZJXP","label":"DB2 Tools for z\/OS"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"12.1.0","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
01 February 2023