사용자 도구

사이트 도구


oracle:wm_concat

WM_CONCAT is gone 12c

Hi tom, when i tried use this wm_concat() function in 12c i'm getting this error can you briefly explain?

ORA-00904: “WM_CONCAT”: invalid identifier 00904. 00000 - “%s: invalid identifier and we said… WM_CONCAT is gone in 12c.

Use LISTAGG instead

SQL> SELECT deptno, listagg(ename, ',') WITHIN GROUP (ORDER BY ename) AS employees
  2  FROM   emp
  3  GROUP BY deptno;
 
    DEPTNO EMPLOYEES
---------- ------------------------------------------------------------
        10 CLARK,KING,MILLER
        20 ADAMS,FORD,JONES,SCOTT,SMITH
        30 ALLEN,BLAKE,JAMES,MARTIN,TURNER,WARD
oracle/wm_concat.txt · 마지막으로 수정됨: 2025/04/15 10:05 저자 127.0.0.1