Forum Discussion
dsalony
4 years agoHelper I
Indexing a value
I have data that has a value that has two attributes: the value is '# of people' one attribute is Building Name other attribute is Leader Name so something like this: the column 'prim...
- 4 years ago
Hi dsalony ,
Please try:
Primary = var _maxpeople = MAXX(FILTER('Table',[Building]=EARLIER('Table'[Building])),[People]) return MAXX(FILTER('Table',[Building]=EARLIER('Table'[Building])&&[People]=_maxpeople),[Leader])Output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Ashish_Mathur
4 years agoSuper User
Hi,
This calculated column formula works
=LOOKUPVALUE(Data[Leader],Data[People],CALCULATE(MAX(Data[People]),FILTER(Data,Data[Building]=EARLIER(Data[Building]))),Data[Building],Data[Building])
Hope this helps.