IBM Support

IC72775: SQL0171N ERROR WHEN TRIMMING LARGE OBJECT TO 0 LENGTH USING DBMS_LOB.TRIM_CLOB or DBMS_LOB.TRIM_BLOB

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • PL/SQL procedure gets SQL0171N error when attempts to trim a
    large object by TRIM_CLOB or TRIM_BLOB to 0 length.
    
    Sample procedure
    
    CREATE OR REPLACE PROCEDURE TEST AS
    DECLARE
        req CLOB := EMPTY_CLOB' ;
        str VARCHAR (300);
    BEGIN
        DBMS_LOB.open_clob (req, 1);
        str := 'aaa,';
        DBMS_LOB.writeappend_clob (req, LENGTH(str), str);
    
        DBMS_LOB.trim_clob (req, 1);
        DBMS_OUTPUT.put_line ('req: ' || VARCHAR(req));
    
        DBMS_LOB.trim_clob (req, 0);
        DBMS_OUTPUT.put_line ('req: ' || VARCHAR(req));
    
        DBMS_LOB.close_clob (req);
    END;
    
    The second trim results in SQL0171N.
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * ALL                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * PL/SQL procedure gets SQL0171N error when attempts to trim a *
    * large object to 0 length by TRIM_CLOB or TRIM_BLOB routine.  *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to version 9.7 FixPack4                              *
    ****************************************************************
    

Problem conclusion

  • This was first fixed by V97 FP4
    

Temporary fix

Comments

APAR Information

  • APAR number

    IC72775

  • 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

    2010-11-23

  • Closed date

    2011-05-09

  • Last modified date

    2011-05-09

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

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

    IC72905

Fix information

  • Fixed component name

    DB2 FOR LUW

  • Fixed component ID

    DB2FORLUW

Applicable component levels

  • R970 PSY

       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:
09 May 2011