Hello,
I am having trouble with a simple multiplication expression in my flow.
I have two SharePoint lists. One list has a list of properties, the other a list of tenancies in each property. Each tenancy occupies a portion of the property (e.g. Tenancy 1 = 31%, Tenancy 2 = 35%, Tenancy 3 = 34%). I am trying to update a column in the Tenancy list with a multiplication of the 'portion' attributed to each individual tenancy and an overall 'cost' for the property in the Property list. Essentially I want a column ('portion of cost') in the tenancy list to be updated with the cost attributed to each tenancy.
Using a Created or Modified trigger, I am able to return the list of tenancies from the Tenancy list for the property that is modified in the Property list. However, when I try updating the items using an expression the Dynamic Content is only offering options in the Property list so I am unable to include the 'portion' column in my multiplication expression. To get around this I initialized a variable ('Outgoings Portion') and using Apply To Each after getting the items set the variable to equal the 'portion' value. This appears to set the correct value to each list item that is retrieved from the Tenancy list, however, when I use the variable in the multiplication expression it uses the first value assigned for (e.g. 31% for all items) instead of the respective portion for each.
I am really struggling to see what I am doing wrong. Please see screenshots below:


This multiplication expression has been inserted in the 'portion of cost' field in the Update Item function pictured above:
mul(variables('Outgoings Portion'),triggerBody()?['cost'])
Any assistance would be greatly appreciated!