If the record is found in the Source Data table, the fields populate and the user can verify/edit and save.
If the record not found, the user enters information in the blank fields and saves to the Source Data table.
All records saved are also logged and saved in the Change_Log table.
Any records saved are also added or updated in the Local_Data table. This table records the users record saves for that day or session. If the record doesn’t exist in the Local_Data table it is added to it. If the record exists it can only be updated.
Source_Data table has all of the data stored, the Local_Data table only mirrors changes to the Source_Data table during an inventory session.
The issue I have is when a record exisist in both the Source_Data and the Local_Data tables, I can only get the Source_Data table to update.
I am not sure if it has to do with my keys and the refs i have set up or not
Below is the setup , I am very new to this, any help or comments will be much appreciated.
A question…why do you have the Local_Data table at all?I ask because as you said you are new and maybe you have this table due to a mis-understanding of what is actually needed. I avoided asking previously because I didn’t want to influence your design. But, it seems unnecessary to have a table with duplicated information. So, if you do not need it for any practical reason then maybe the best solution is to remove this table.
Otherwise…
How does it Fail? Do you get an error message? What does the Audit Log show happening for this Add Row to Local_Data?
A few things to clarify:
I am not seeing in any of the details you provided, anything that actually adds to the table “Local_Data”. There is something called “AddLocalRecord” but it shows the “Table to add to” as Source_Data. Maybe this is a typo?
In the item named GroupTrigger there is a reference to “AddRecord” but I see nothing labeled this way.
I am not clear if these set of actions are executed on the “Form Saved” behavior or by Automation. The nature of your details implies by Automation. Is this all included in a single Bot?
For what it’s worth, instead of spending the time to type out elaborate details, it is MUCH better to simply take a screen capture and include that. Manual typing is prone to typo’s, mis-translated details AND forces us, the Community, to understand yet another interpretation of the implementation.
Ok after reading your post I dismantled the project and found a missing expression for AddLocalRecord, and corrected GroupTrigger actions. Whew, it works!!!