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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Powerwoman
Helper II
Helper II

Running Total not working in calculated column

Hi there,

can anyone tell me, why this DAX isn't working but always showing the total instead of running total?
Running totals should be calculated by item.

remainingNew =
 CALCULATE(
    sum(itemLedgerEntryPurchase[amount])
    , ALLEXCEPT(itemLedgerEntryPurchase,itemLedgerEntryPurchase[item])
    ,itemLedgerEntryPurchase[Index] <= MAX(itemLedgerEntryPurchase[Index]
))
 
Powerwoman_0-1697004678490.png

 

Thanx!

 

1 ACCEPTED SOLUTION
ThxAlot
Super User
Super User

 

remainingNew =
VAR __idx = itemLedgerEntryPurchase[Index]
RETURN
    CALCULATE(
        SUM( itemLedgerEntryPurchase[amount] ),
        ALLEXCEPT( itemLedgerEntryPurchase, itemLedgerEntryPurchase[item] ),
        itemLedgerEntryPurchase[Index] <= __idx
    )


Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LeanAndPractise(Everyday)


)



View solution in original post

2 REPLIES 2
nirali_arora
Resolver II
Resolver II

You can try the following dax measure

Running Total =

SUMX(

FILTER(

ALL(YourTable),

YourTable[Index] <= MAX(YourTable[Index]) ),

YourTable[ValueColumn]

)

ThxAlot
Super User
Super User

 

remainingNew =
VAR __idx = itemLedgerEntryPurchase[Index]
RETURN
    CALCULATE(
        SUM( itemLedgerEntryPurchase[amount] ),
        ALLEXCEPT( itemLedgerEntryPurchase, itemLedgerEntryPurchase[item] ),
        itemLedgerEntryPurchase[Index] <= __idx
    )


Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LeanAndPractise(Everyday)


)



Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

Check out the July 2024 Power BI update to learn about new features.

July Newsletter

Fabric Community Update - July 2024

Find out what's new and trending in the Fabric Community.