distinct listagg

One limitation in listagg, you cannot use DISTINCT. Okay, there are plenty of distinct-capable listagg workarounds, but to get the real listagg working, it is a bit of an headache With one listagg SELECT DEPTNO, LISTAGG (JOB, ‘,’) WITHIN GROUP (ORDER BY JOB) JOBS FROM ( SELECT DISTINCT DEPTNO, JOB FROM EMP) GROUP BY DEPTNO; […]

disable commit in procedure

There is an obscure syntax that prevents a procedure from issuing a commit alter session DISABLE COMMIT IN PROCEDURE; According to the doc, it prevents procedure from committing your data Test case SQL> alter session DISABLE COMMIT IN PROCEDURE Session altered. SQL> create table t(x number) Table created. SQL> create or replace procedure p is […]