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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Bamse
Frequent Visitor

Questions about lack of support for MEDIANX in GROUPBY / CURRENTGRUUP

I am using GROUPBY in several queries and are running into an issue.
According to Microsoft's documentation GROUPBY supports the aggregation (X) functions for grouping data.
But they also write that CURRENTGROUP on which it depends only supports a subset of the 'X' functions.
More specifically I am missing 'MEDIANX' which does not work with CURRENTGROUP and therefore not with GROUPBY.
I read some questions, also on this forum about this issue where people see it as a bug.


My question(s) are:
- Is it indeed a bug that MEDIANX is not supported, or is there some logic behind it?
- Is there a clever workaround (maybe with SUMMARIZE?) which produces the same results as GROUPBY, but with support for MEDIANX?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

I've never in my life used GROUPBY, even though I've been practising DAX for more than 4 years and created huge commercial models.

There's no need for this 99.99999% of time. Use the combination of ADDCOLUMNS/SUMMARIZE. Beware, though, NOT to do any calculations under SUMMARIZE. Use it only for grouping rows. Nothing more. Deviate from this and you'll be in trouble in no time.

Best
D

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

I've never in my life used GROUPBY, even though I've been practising DAX for more than 4 years and created huge commercial models.

There's no need for this 99.99999% of time. Use the combination of ADDCOLUMNS/SUMMARIZE. Beware, though, NOT to do any calculations under SUMMARIZE. Use it only for grouping rows. Nothing more. Deviate from this and you'll be in trouble in no time.

Best
D
Anonymous
Not applicable

By the way, you don't have to use MEDIANX. You can use MEDIAN if you have the right filter context and just one column to calculate this value on.

Best
D

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

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.