is it possible to load data into multiple tables using INSERT ALL
without adding duplications or without using overwrite
to accomplish it?
As WHEN
clause doesn't support subqueries unless it returns a value to compare with something else, i am currently trying with the following:
INSERT ALL
INTO TEMP (PKEY, TITLE) VALUES ( ID, TITLE_NAME )
SELECT
$1 AS ID,
$2 AS TITLE_NAME
FROM @azure_stg/mti_test.csv (FILE_FORMAT=>'CSV')
WHERE $1 NOT IN (SELECT PKEY FROM TEMP)
my aim is to add another 3 tables to be filled with data in parallel within the same query without adding duplications. so I tried to add another into table2 select ...
but it didn't work.