The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
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
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.
Proud to be a 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] )
)
)
Proud to be a Super User!