Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

How to model merge/truncate with a staging table?

How to model merge/truncate with a staging table?

New Contributor

My flow is getting data from one database and inputting the data into another. Because I want to Insert/Update the data in the target table I insert the data into a staging table. Afterwards I merge the staging table with the "final" table and truncate the staging table.


However if some data gets put into the staging table in the meantime (between merge and truncate) then I lose that data.

How could i model the flow to make sure this does not happen?


Below is my current "wrong" implementation.

107565-1554189487501.png

1 REPLY 1

Re: How to model merge/truncate with a staging table?

New Contributor

Hi , I am having exatly the same issue . Did you manage to resolve this issue ?