Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Syndicate_Admin
Administrator
Administrator

Show Max value for each item in a gallery

Hi,

 

 I am trying to show the max weight recorded for each exercise in a gallery.

I can successfully filter by specific numbers, but would like to use the Max function instead.

My query is as follows:

Filter(SortByColumns(
WorkoutLogs,"cr503_weightkg",
SortOrder.Descending
),'Weight (kg)'=84)

 

thanks in advance

3 REPLIES 3
Syndicate_Admin
Administrator
Administrator

Thanks for the above,

 

 Unfortunately I need this for a PowerApps Gallery, so Power fx please.

I'm unable to use a DAX measure.

 

tried converting it.

 

ClearCollect(
MaxWeightsByExercise,
ForAll(
Distinct(WorkoutLogs, 'cr503_exercise'),
LookUp(
WorkoutLogs,
'cr503_exercise' = Result,
'Weight (kg)' = Max(Filter(WorkoutLogs, 'cr503_exercise' = Result), 'Weight (kg)')
)
)
)

 

sorry if it doesn't help you.

 

rubayatyasmin_0-1689517080227.png 


Did I answer your question? Mark my post as a solution!super-user-logo

Proud to be a Super User!


rubayatyasmin
Super User
Super User

Hi, @Syndicate_Admin 

 

see if this works. 

 

Max Weight =
CALCULATE (
MAX ( WorkoutLogs[Weight (kg)] ),
FILTER (
ALL ( WorkoutLogs[Exercise] ),
WorkoutLogs[Exercise] = MAX ( WorkoutLogs[Exercise] )
)
)

 

 

rubayatyasmin_0-1689517080227.png


Did I answer your question? Mark my post as a solution!super-user-logo

Proud to be a Super User!


Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.