AnsweredAssumed Answered

Refreshing/Updating records entered by a script

Question asked by timraudies on Jul 1, 2018
Latest reply on Jul 4, 2018 by keywords

Hello everyone,

 

At the moment I am working on a business solution, in which I want to make the transfer between an Order and the actual Production Line Items. I startet with a simple Customer-Orders-Order Line Items-Products solution.

 

From here I now want to transfer all ordered products into the "Production Line" table, which basically is a copy of the Order Line Items Table, but each ordered item gets its own entry. I wrote a script which loops through the entered quantity and gives all single items a new serial number.

 

Right now I attached this script to a button, which I labeled "Refresh". But here is the problem: whenever I hit that button it loops through all items again and adds them again to my production line. When I delete all records in the script before starting the loop, the auto entered serial number also changes, so this can't be the solution..

 

How can I make the script check, wether the specific item (serial number) has already been added to the table or not?

 

Thanks for any help!

 

Tim

Outcomes