Power Pivot: Working on corresponding values of maximum values

gifariz

Board Regular
Joined
May 2, 2021
Messages
128
Office Version
  1. 365
Platform
  1. Windows
Hi all, new here. I am working on a data more than 1 million rows, so I need to work it on Power Pivot. Let's say this data has column A and B. When I make the pivot table of this data, I can get the maximum value of column A. Let's say column A has 4 cells containing this value. I want to get the minimum value among the 4 cells in column B corresponding those max of A.

I can do this in normal sheet. First, by counting the number of cells equal to max value of A: countMaxA=COUNTIF(A:A,maxA). Then, sort the range "A:B" by column A. Then, get the minimum of corresponding B by minCorrB=MIN(OFFSET(B1,MATCH(maxA,A:A,0)-1,0,countMaxA,1)).

But I dont know how to do this in Power Pivot. Any suggestion?
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
CALCULATE(MIN(Table1[val b]);FILTER(Table1;Table1[val a]=MAX(Table1[val a])))
 
Upvote 0
Solution

Forum statistics

Threads
1,224,820
Messages
6,181,154
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top