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 Apps / Sum and Filter on more...
Power Apps
Unanswered

Sum and Filter on more than one source data

(0) ShareShare
ReportReport
Posted on by 14

Context

I'm building an app that use SP lists and Excel table

 

In the SP lists, I have 

- "Template list"

a template is a container, identified with an Title ''MET000105' is one, and that contains a text field"linked project", 'PM00016/PM00017' , which are 2 projects

 

In the Excel table, I have mainly budget data

like 

Project - subproject - Budget

PM00016 - PR00123 - 750

PM00016 - PR00234 - 200

PM00017 - PR00566 - 300

 

I'd like to calculate and display, in a field of one of my screen  the total amount of budget for all linked project in the text field

When I had only PM00016 in the Text field in the template list item, I used
Sum(Filter(Tableau1;Codeprojetmétier=ListeTemplate.Selected.'Liste des projets metier');'Budget validé projet opérateur (BVE)')

that gave the good result

 

Now I change to PM00016/PM00017 and would like to do the same

I sense there is something to do maybe with ForAll and Split; but  I can find it...

Categories:
I have the same question (0)
  • mmbr1606 Profile Picture
    14,629 Super User 2026 Season 1 on at

    hey @BenjaminJarry72 

     

    can u try this:

    Set(
     ProjectList,
     Split(ListeTemplate.Selected.'linked project', '/')
    );
    
    Sum(
     ForAll(
     ProjectList,
     Sum(
     Filter(
     Tableau1,
     Codeprojetmétier = Result
     ),
     'Budget validé projet opérateur (BVE)'
     )
     ),
     Value
    )
    

     

    Let me know if my answer helped solving your issue.

    If it did please accept as solution and give it a thumbs up so we can help others in the community.



    Greetings

  • BenjaminJarry72 Profile Picture
    14 on at

    I got a unknown error

    Behavior function in a non-behavioral property. You cannot use this property to modify values elsewhere in the application

     

    I guess, the SET function is not accepted within a Text attribute of a label

  • mmbr1606 Profile Picture
    14,629 Super User 2026 Season 1 on at

    try this instead.

    onvisible of screen for example:

    Set(
     ProjectList,
     Split(ListeTemplate.Selected.'linked project', '/')
    );
    Set(
     TotalBudget,
     Sum(
     ForAll(
     ProjectList,
     Sum(
     Filter(
     Tableau1,
     Codeprojetmétier = Result
     ),
     'Budget validé projet opérateur (BVE)'
     )
     ),
     Value
     )
    );
    

     

    Textlabel Text property:

    Text(TotalBudget)
    

     

    Let me know if my answer helped solving your issue.

    If it did please accept as solution and give it a thumbs up so we can help others in the community.



    Greetings

  • BenjaminJarry72 Profile Picture
    14 on at

    "Result" is not recognized and give an error

     

    "Name is not valid "Result" is not recognized"

     

  • BenjaminJarry72 Profile Picture
    14 on at

    I changed to 
    (Result changed to Value)

    Set(
     ProjectList,
     Split(ListeTemplate.Selected.'linked project', '/')
    );
    Set(
     TotalBudget,
     Sum(
     ForAll(
     ProjectList,
     Sum(
     Filter(
     Tableau1,
     Codeprojetmétier = Value
     ),
     'Budget validé projet opérateur (BVE)'
     )
     ),
     Value
     )
    );

     

     

    BUT 

    the sum is not working then

     

    BenjaminJarry72_0-1715692303911.png

     

    I should have 14440 and the results give me only 7500 as if it sums up only for PM000016

  • mmbr1606 Profile Picture
    14,629 Super User 2026 Season 1 on at

    what kind of column is Codeprojetmétier?

  • BenjaminJarry72 Profile Picture
    14 on at

    It's a text column into my Excel table / file

    it's what I called "Linked project" in my context 😉

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 392 Most Valuable Professional

#2
11manish Profile Picture

11manish 136 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 109 Super User 2026 Season 2

Last 30 days Overall leaderboard