Hi all, have three tables with inventory for three headquarters, Farma, Piñonal I and Piñonal II, I have another table named TRASLADOS where are registered all the transfers between headquarters, all the transfers are correctly stored in the table TRASLADOS, this is made with an action of the type go to another view in this app directed to a form view with several prefilled values, then in the TRASLADOS table I have a compound action which first writes the registry of the transfer in the table corresponding headquarter, after that another action indide the compound action updates the inventory quantity of the specific asset in the destination table (all of this works correctly).
I have a third type of action inside the compount action of the type execute an action on a set of rows in the TRASLADOS table, this last action calls an action to substract the transfered quantity of an asset, which is stored in the TRASLADOS table, from the original quantity of that asset stored in the table of the inventory of the original headquarter; this last action doesn´t work at all.
Looking in another post I read and found an example app, in that app is explained that it must be an parent table and a child table related between them through Refs, in my case I think it should be the parent table the inventory table of one headquarter and the child table the table TRASLADOS, the problem with this is that it doesn´t works for me because I have at least three tables (one for each headquarter) all of them can´t be parent tables of the TABLE traslados.
The problem I have is that is imposible to me to mantain the context, in this case the context I want to mantain it by store the ID_ACTIVO (code) of the asset to use it to select the row for update it existence quantity of the asset in the table of the original headquarter by its ID_ACTIVO column.
I don´t know what to do next to solve the problem altough now Iḿ thinking about making a TRASLADOS table for each headquarter, this will allow me to have a parent table and a child table for each headquartes but this probably will make things harder.
So, please someone help me to acomplish the objective.
I’ll update some pictures to show the problem
The descontar action never is applied and I don´t know why but I assume that the lookup function is unable to retrieve the ID_ACTIVO value to transfer it to the actions for the destination table.
Note that in the grouped action are what it seems repeated action but the actions names are terminated with the destination table in which they will be applied, right now I’m interested in the FARM actions. For the others can be copied the outcome of this post
What can I do to solve it?. Thanks in advance for the help
grouped action
descontar action
condition to apply the descontar action
formula to select rows in the descontar action
restar action
formula to update the value of the CANTIDAD ACTUAL column in the destination table, using the restar action





