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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Julia997
Frequent Visitor

ABC statics filter

I have try to create ABC analysis, I have done the first cumulated but after that I found difficult.

 

My dataset is like this https://1drv.ms/x/s!AvMy-Bzzx3mqgwmKSZm6wr_W4VXr?e=Jwwbji&nav=MTVfezAwMDAwMDAwLTAwMDEtMDAwMC0wMDAwLT...

 

I need to diversify for each year (statical filter), how can I add?

 

RANK = RANKX(ALLSELECTED('TABLE'[NAME]),[FATT],,DESC,Dense)
 
M_Running total =
VAR _currentrank = [RANK]
VAR _t1 =
    CALCULATETABLE (
        SUMMARIZE ( 'TABLE', 'TABLE'[NAME] ),
        ALLSELECTED ( 'TABLE' )
    )
VAR _t2 =
    ADDCOLUMNS (
        _t1,
        "@Total", CALCULATE ( SUM ( 'TABLE'[FATT] ) ),
        "@Rank", [RANK]
    )
RETURN
    IF (
        ISINSCOPE ( 'TABLE'[NAME] ),
        SUMX ( FILTER ( _t2, [@Rank] <= _currentrank ), [@Total] )
    )

 

EDIT: how can I calculated the cumulated? I have try Measure= CALCULATE(SUM[Column]), ALL(Table)) but it doesn't work

2 REPLIES 2
MasterSonic
Helper IV
Helper IV

this perhaps

RANK = RANKX(FILTER(ALL('TABLE'), YEAR('TABLE'[DATE]) = SELECTEDVALUE(YEAR('TABLE'[DATE]))),[FATT],,DESC,Dense)

 

M_Running total = SUMX( FILTER( SUMMARIZE( 'TABLE', 'TABLE'[NAME], "Year", YEAR('TABLE'[DATE]) ), (YEAR('TABLE'[DATE]) = SELECTEDVALUE(YEAR('TABLE'[DATE]))) && (RANKX(FILTER(ALL('TABLE'), YEAR('TABLE'[DATE]) = SELECTEDVALUE(YEAR('TABLE'[DATE]))),[FATT],,DESC,Dense) <= [RANK]) ), SUM('TABLE'[FATT]) )

My year in this case is a text, not a date. How can I do? The second DAX doesn't work

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.