web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Sum column by unique i...
Power Automate
Answered

Sum column by unique id and send to another sharepoint list

(0) ShareShare
ReportReport
Posted on by 10

I have two separate sharepoint lists.  List "A" shows all invoices received to date and references a TacticID that is unique to a specific deliverable.  This list has multiple invoice "Amounts" per deliverable ("TacticID").

jarkins_0-1651256834330.png

 

Sharepoint list "B" has more detail related to each TacticID (i.e. deliverables and timelines) including a column for total amount of invoices received.

 

I am trying to sum all of the invoice "Amount" values for a given "TacticID" from "List A" to the "Total Invoice" column of the matching "TacticID" on "List B".  Ideally each deliverable in "List B" would have the corresponding invoice totals showing up in the "Total Invoice" column of "List B". 

 

I have been trying to make this happen for a couple of days now, but I have not found any good solution to it.  Any help would be greatly appreciated

Categories:
I have the same question (0)
  • Verified answer
    v-yujincui-msft Profile Picture
    Microsoft Employee on at

    Hi @jarkins ,

     

    I have made simple test for your reference.

     

    1. Here are my lists.

    vyujincuimsft_0-1651564760964.png

    vyujincuimsft_1-1651565884017.png

    2. Here are my Flow.

    1. Get all TacticID values and de-duplicate them.

    2. Sum the Amount column for all records corresponding to each TacticID.

    3. Find the corresponding Item ID for each TacticID in another list.

    4. Update the value of the Total Invoice column in another list.

     

    union(variables('TacticIDArray'),variables('TacticIDArray'))
    TacticID eq '@{item()}'
    first(outputs('Get_items_3')?['body/value'])?['ID']

     

    vyujincuimsft_2-1651565973698.png

    vyujincuimsft_3-1651566101347.png

    vyujincuimsft_4-1651566240029.png

    vyujincuimsft_4-1651628411092.png

    vyujincuimsft_6-1651566566844.png

     

    Result Screenshots:

    vyujincuimsft_7-1651566607493.pngvyujincuimsft_8-1651566642051.png

    vyujincuimsft_9-1651566652007.png

     

     

     

    Best Regards,

    Charlie Choi

  • jarkins Profile Picture
    10 on at

    thank you @v-yujincui-msft.  I have tried the flow you suggested, but keep running into the error below.  I ended up changing a few column names from the original request (ie TacticID in invoices to Tactic), but I am still running into the error. 

     

    jarkins_0-1651588534041.png

     Here is the flow I used:

     

    jarkins_1-1651588590777.pngjarkins_2-1651588623291.pngjarkins_3-1651588694757.pngjarkins_4-1651588726202.pngjarkins_5-1651588755899.pngjarkins_6-1651588770296.png

     

    Any help would be greatly appreciated. Thanks

  • v-yujincui-msft Profile Picture
    Microsoft Employee on at

    Hi @jarkins ,

     

    Based on the error details, it seems that you are using a wrong internal column name.

    vyujincuimsft_0-1651626703209.png

    You could find the internal column names by clicking on the list settings.

    vyujincuimsft_1-1651627171997.png

    vyujincuimsft_2-1651627248277.png

    vyujincuimsft_3-1651627323705.png

     

     

    Best Regards,

    Charlie Choi

  • jarkins Profile Picture
    10 on at

    Thanks @v-yujincui-msft .  That was my initial assumption as well and what led me to change the column name from TacticID to Tactic.  The error references a failure in Get_items_2 which is related to "InvoiceTracker".

     

    jarkins_0-1651664856802.png

     

    However, when I go into list details as you suggested, I see a column labeled "Tactic".

    jarkins_1-1651664973280.png

    the Filter query used in Get_items_2 is Tactic eq '@{item()}'  

  • v-yujincui-msft Profile Picture
    Microsoft Employee on at

    Hi @jarkins ,

     

    You could click on it and see the address bar at the top of the page.

    vyujincuimsft_0-1651714003821.png

     

    Best Regards,

    Charlie Choi

  • jarkins Profile Picture
    10 on at

    Yes, the column name is "Tactic", so I do not understand the error being generated that says the column name cannot be found.

     

    jarkins_0-1651751682083.png

    The address bar has: 

    jarkins_1-1651751793487.png

     

  • v-yujincui-msft Profile Picture
    Microsoft Employee on at

    Hi @jarkins ,

     

    Based on the address bar your provided, field_2 is the internal column name of your Tactic column.

     

    vyujincuimsft_0-1651799373353.png

     

    Best Regards,

    Charlie Choi

     

  • v-yujincui-msft Profile Picture
    Microsoft Employee on at

    Hi @jarkins ,

     

    Is your problem solved?

     

    Best Regards,

    Charlie Choi

  • jarkins Profile Picture
    10 on at

    All set and works now.  Thank you for all your help

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 103 Super User 2026 Season 1

#2
Haque Profile Picture

Haque 87

#3
trice602 Profile Picture

trice602 63 Super User 2026 Season 1

Last 30 days Overall leaderboard