IBM Support

IT22946: LPAD/RPAD RETURN EMPTY STRING INSTEAD OF NULL IN ORA-MODE DATABASE

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • Builtin functions SYSIBM.LPAD and SYSIBM.RPAD should return NULL
    instead of an empty string in an ORA-mode database.  In DB2
    v11.1.2 only, if all the arguments are constants, and the second
    argument is 0, an empty string is returned instead of the
    expected NULL:
    
         values (lpad('abc',0), length(lpad('abc',0)))
    
         1 2
         - -----------
                     0
    
           1 record(s) selected.
    
    
    The correct result should be:
    
         values (lpad('abc',0), length(lpad('abc',0)))
    
         1 2
         - -----------
         -           -
    
           1 record(s) selected.
    

Local fix

  • Enable statement concentrator on the database:
    
         update db cfg for <dbname> using stmt_conc literals
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * ALL                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * See Error Description                                        *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to Db2 11.1 Mod 2 Fix Pack 2 iFix002 or higher       *
    ****************************************************************
    

Problem conclusion

  • First fixed in Db2 11.1 Mod 2 Fix Pack 2 iFix002
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT22946

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    B10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2017-10-26

  • Closed date

    2017-12-22

  • Last modified date

    2017-12-22

  • 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

  • RB10 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":"11.1","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
22 December 2017