Anda tidak dapat menggunakan klausa WITH di mana pun kecuali dalam pernyataan SELECT. Lihat dokumentasi di sini. :
Jadi, Anda dapat melakukan sesuatu seperti ini (11g diuji):
MERGE INTO animalia d
USING (WITH X AS
(SELECT 'moo' AS COW, 'woof' AS CAT,
(SELECT MAX( DECIBELS )
FROM ANIMALIA
WHERE COW = 'moo' ) AS DECIBELS
FROM DUAL )
SELECT * FROM X) q ON (1 = 1)
WHEN MATCHED THEN UPDATE SET d.cow = q.cow||' and more';