Esta é a sintaxe para inserir em uma tabela de um CTE:
-- CREATE TABLE tmp ( tmp_id NUMBER(10) );
INSERT INTO tmp( tmp_id )
WITH cte AS (
SELECT 1 AS tmp_id FROM dual
)
SELECT tmp_id
FROM cte;
-- CREATE TABLE tmp ( tmp_id NUMBER(10) );
INSERT INTO tmp( tmp_id )
WITH cte AS (
SELECT 1 AS tmp_id FROM dual
)
SELECT tmp_id
FROM cte;