Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Running total by group and by date

Hello, I have the following table and i am trying to create a running total column for the Invoice column for each Document ID by Received date. The date format is: dd/mm/yy From my understanding, ...
  • Anonymous's avatar
    Anonymous
    4 years ago

    HotChilli I have created the following quick measure:

     

    The corresponding auto-generated DAX code:

    Invoice running total in Received = 
    CALCULATE(
    	SUM('Invoice Table'[Invoice]),
    	FILTER(
    		ALLSELECTED('Invoice Table'[Received]),
    		ISONORAFTER('Invoice Table'[Received], MAX('Invoice Table'[Received]), DESC)
    	)
    )

     

    The results in a table is correct: