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 / Multiply the values in...
Power Apps
Answered

Multiply the values in a column

(0) ShareShare
ReportReport
Posted on by 29

Hi,

 

I have collated multiple tables into one overall table which is named OverallTable.

 

The OverallTable has multiple fields:

ByPA_0-1633916699050.png

 

The Overall Table has about 40 records.

 

I am trying to get a multiplication of all the rows in RF i.e. 1 x 1 x 1.1822 x 1.100 x 0.7 x 1 x 0.4...

 

but I understand that PowerApps has no such function.

 

I am trying to follow the suggestion below:

https://powerusers.microsoft.com/t5/Building-Power-Apps/Calculate-Product-Multiply-all-numbers-in-a-collection/td-p/559301

 

and ended up with

 

 

 

 

 

ClearCollect(NumColTest,{total:1});
ForAll(OverallTable,Patch(NumColTest,First(NumColTest),{total:First(NumColTest).total*CountRows(OverallTable)}));

 

 

 

 

 

However, I want to have the product of the column RF, so so I tweak it:

 

 

 

 

ForAll(OverallTable.RF,Patch(NumColTest,First(NumColTest),{total:First(NumColTest).total*CountRows(OverallTable)}));

 

 

 

 

 

A first look at NumColTest doesn't seem right, assuming it is the product of the RFs.

 

Below is when I force the number of records to be 2:

 

ForAll(OverallTable.RF,Patch(NumColTest,First(NumColTest),{total:First(NumColTest).total*2}));

 

 

ByPA_0-1633915078156.png

 

 

Wondering if anybody has any ideas? Thank you.

 

Categories:
  • StalinPonnusamy Profile Picture
    Super User 2024 Season 1 on at

    Hi @ByPA 

     

     

    ClearCollect(OverallTable, {RF:1,RS:"1000000"},{RF:1,RS:"Administrative"},{RF:1.18,RS:"1000000"},{RF:1.10},{RF:0.7,RS:"1250"});
    ClearCollect(NumColTest,{total:1});
    ForAll(OverallTable,Patch(NumColTest,First(NumColTest),{total:First(NumColTest).total*RF})) 

     

     

    Set Lable Text Property to

     

    First(NumColTest).total

     

     

    Example (1 * 1.18 * 1.10 * 0.7) = 0.9086 (As per my sample data)

     

    StalinPonnusamy_1-1633922895858.png

     

     

  • Verified answer
    StalinPonnusamy Profile Picture
    Super User 2024 Season 1 on at

    Hi @ByPA 

     

    Updated the above post as per your data.

     

  • ByPA Profile Picture
    29 on at
    It is definitely looking more reasonable now! Thanks so much!

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 396 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 323

#3
WarrenBelz Profile Picture

WarrenBelz 193 Most Valuable Professional

Last 30 days Overall leaderboard