IBM Support

IC75034: A QUERY WITH A PREDICATE OF "QUERYTAG=?" OR "QUERYNO=?" MAY REPORT A SQL0901N ERROR

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • When you submit a query, DB2 will report error SQL0901N when all
    of the following conditions are met:
    
    - The query contains the predicate "QUERYTAG=?" or "QUERYNO=?";
    
    - The query contains another predicate with a literal value that
    may be replaced with a host variable if the statement
    concentrator is turned ON; that is, if the database
    configuration parameter STMT_CONC is set to LITERALS.
    
    For example,
    
    # Create a table named TEST with a column named QUERYTAG.
    db2 "create table TEST(C1 char(1) not null, QUERYTAG char(1) not
    null)"
    
    # Issue a SELECT sql with two predicates: One is QUERYTAG=? and
    # the other one is C1='P'.  You will see a SQL0901N error.
    
    db2 "select * from TEST where C1='P' and QUERYTAG=?"
    
    SQL0901N  The SQL statement failed because of a non-severe
    system error. Subsequent SQL statements can be processed.
    (Reason "Parameter marker in literal replaced statement".)
    SQLSTATE=58004
    

Local fix

  • Turn the statement concentrator off, i.e.,
    
    db2 "update db cfg for <dbname> using STMT_CONC OFF"
    
    replacing <dbname> with the database name.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * All                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * See error description.                                       *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to DB2 Version 9.7 Fix Pack 5 or newer               *
    ****************************************************************
    

Problem conclusion

  • First Fixed in DB2 Version 9.7 fix pack 5
    

Temporary fix

Comments

APAR Information

  • APAR number

    IC75034

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    970

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2011-03-15

  • Closed date

    2012-01-19

  • Last modified date

    2012-01-19

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

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

Fix information

  • Fixed component name

    DB2 FOR LUW

  • Fixed component ID

    DB2FORLUW

Applicable component levels

  • R970 PSN

       UP

[{"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SSEPGG","label":"DB2 for Linux, UNIX and Windows"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"9.7","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
19 January 2012