Hello
I am building a better annual leave process for my team and I have a starting balance of 28 in a column (sharepoint list) stating Balance remaining, then every time they request time off I would like the no of days to be minus'd from the previous balance remaining and updated on the item.
So if they take 2 days off on the 1st request it would update balance remaining with 26, then 5 days on the 2nd request it would update to 21 etc.
I was going to do this within the sharepoint however I dont think the calculated column can work so I thought power automate would be better.
I have created the flow based on a new item created, get item, send for approval, when I approve, update item with approved and with the new balance remaining.
I thought it I pick up Get Item (current item) and get items (all items) I could
sub (Balance remaining (from all items), (No of days requested(from current item)
How this just falls over can I use get items for the balance and make it look only at the previous row? I know how to do this in excel just cant get sharepoint or flow to look at the previous row
Any help would be greatly appreciated @Reza