How WHEN
clause evaluate values of columns in order to insert only new values and skip existing ones when using the following query:
INSERT ALL
WHEN (SELECT COUNT(*) FROM DEST WHERE DEST.ID = NEW_ID) = 0 THEN
INSERT INTO DEST (ID) VALUES (NEW_ID)
SELECT NEW_ID FROM SRC
I tried with WHEN NEW_ID NOT IN (SELECT...) THEN
But it didn't work and threw an error of unsupported.
Does it create a virtual column in all rows with values of true or false and then add all rows having true as a result?