Identify the rows uploaded in an import action

I have 2 tables, PAYMENT and ORDER.

PAYMENT has an Order ID, Bank Ref Num, Amount, Date. This table is filled with an import action from a csv file

An action is triggered with a bot when a new row is added to the table PAYMENT, and I want to copy these columns to the ORDER table so each Order have now the payment info.

I have been able to execute all this but I need to identify which rows were added in each import. Like an import ID in the table ORDER. This is where I am lost, I can`t figure it out a way to create a unique ID for the import

0 1 141
1 REPLY 1

I am not sure of your exact requirements but here is one idea that may inspire further ideas if you wish to do so.

Create a new table (call it IMPORTS, for instance) with just an ID column with UNIQUEID() set as its initial value. (you can of course add columns such as IMPORT DATE, EXECUTED by, etc as desired.)

Right before you perform an import, create a row in the IMPORTS (I believe a grouped action can do these sequentially.) and use the ID Value in your copy PAYMENTS to ORDERS action using LOOKUP()

Top Labels in this Space