SQL USING WM_CONCAT RUNS SLOWER IN 10.2.0.5 and 11.2.0.2 (Doc ID 1393596.1)

Last updated on JANUARY 12, 2012

Applies to:

Oracle Server - Enterprise Edition - Version: 11.2.0.2 to 11.2.0.3 - Release: 11.2 to 11.2
Oracle Server - Enterprise Edition - Version: 10.2.0.5 to 10.2.0.5   [Release: 10.2 to 10.2]
Information in this document applies to any platform.

Symptoms

SQLs using WM_CONCAT function run slower in 11.2.0.2 and 10.2.0.5 onward. Execution plans
can be exactly same as previous releases that used to run well. TKPROF shows much more QUERY
and CURRENT gets. AWR or Statspack statistics show more counts for 'lob reads' and 'lob writes'.

WMSYS.WM_CONCAT is Workspace Manager internal and undocumented function and not intended
to be used by customer applications.  This function concatenates the values of the input column. For
example:

select deptno,wm_concat(ename) from emp group by deptno ;

DEPTNO WM_CONCAT(ENAME)
---------- --------------------------------------------------------------------------------
10 CLARK,KING,MILLER
20 SMITH,FORD,ADAMS,SCOTT,JONES
30 ALLEN,BLAKE,MARTIN,TURNER,JAMES,WARD



Changes

  Upgraded database to 10.2.0.5 or 11.2.0.2 ( and above ).

The definition of WMSYS.WM_CONCAT function has changed in 11.2.0.2 and 10.2.0.5 onward to
use CLOB.

10.2.0.5, 11.2.0.2+
FUNCTION wm_concat( P1 VARCHAR2 IN ) RETURNS CLOB.

10.2.0.4-, 11.1.0.7-, 11.2.0.1
FUNCTION wm_concat( P1 VARCHAR2 IN ) RETURNS VARCHAR2

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms