Related Rows save order for workflow

Hi I have a workflow that is not triggering as intended and all the relevant actions work on their own. I suspect it has to do with how rows are saved but I just want to confirm here.

I have a invoice log parent table with a invoice details child table for all the line items of the invoice as an IsPartOf ref to enter as a invoice is logged. However my workflow for Invoice logs ADDS should update inventory based on the line items of my invoice details but it does not pull through.

Any Help would be appreciated

Solved Solved
0 4 192
1 ACCEPTED SOLUTION

Perhaps the problem is because when you add a parent and child rows as a single parent row addition, the parent is saved first (triggering the workflow), then the children are saved, so the child rows donโ€™t exist when the parent workflow runs.

See Sending Email Only After Adding a Parent Record and All of Its Children here:

View solution in original post

4 REPLIES 4

Steve
Platinum 4
Platinum 4

If you want to update the parent when a child is added or updated, the workflow needs to be attached to the child table, not the parent table.

I am not making a update to the parent table. The workflow is just based on the ADD for that parent to update values in a inventory table based on the values in the invoice child. Iโ€™ll explain better below.

This is an action that updates the cost of an Item in inventory based on the values on the invoice. The action works perfectly if I click it manually.

Then I have a GetToUpdate action at my invoice log that is a โ€œexecute action on a set of rowsโ€ for all the relevant Inventory Items. This Action also works perfectly if I manually click it.

But then the workflow just refuses to work.

Is this how you understood it or does it change your opinion at all?

Thanks again

Perhaps the problem is because when you add a parent and child rows as a single parent row addition, the parent is saved first (triggering the workflow), then the children are saved, so the child rows donโ€™t exist when the parent workflow runs.

See Sending Email Only After Adding a Parent Record and All of Its Children here:

Thanks this worked!

Top Labels in this Space