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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
caseski
Helper I
Helper I

Graph line with cumulative Sum by category

Hi, I have a table where the bank movements relating to various accounts are recorded, positive (income) and negative (outgoing). I would like to make a graph that shows the balance as a function of time (date). I tried to set up a quick measure (running sum) but it doesn't work.

Here an example of my table:

 

ACCOUNTTYPEDESCRIPTION VALUE      DATE
ALPHA7xxxx $     26.235,3704/11/23
ALPHA7ewcx $     10.605,8404/11/23
ALPHA7xewqdef $     49.955,2004/11/23
ALPHA7ewff $       7.008,0004/11/23
BETA7dfewfd $           878,4004/11/23
BETA7gwe $     14.003,5504/11/23
BETA7hwtht $       9.205,3404/11/23
GAMMA8htrh $       4.861,7004/12/23
ALPHA7sbrb $       7.831,9104/12/23
GAMMA7htwrh $   126.349,2804/12/23
BETA7btwbw $     28.459,1504/12/23
ALPHA7vbvw $   250.578,1204/13/23
BETA7bvrb $ -250.578,1204/13/23
DELTA2btrwesb $            -48,0004/13/23
OMEGA2bbrb $   -25.000,0004/13/23
ALPHA7hg $     25.000,0004/13/23
ZETA2nmnu $   -75.000,0004/13/23

 

 

1 ACCEPTED SOLUTION
johnt75
Super User
Super User

If you have a date table linked to your fact table you can use

Running Total =
VAR CurrentDate =
    MAX ( 'Date'[Date] )
RETURN
    CALCULATE ( SUM ( 'Table'[Value] ), 'Date'[Date] <= CurrentDate )

View solution in original post

1 REPLY 1
johnt75
Super User
Super User

If you have a date table linked to your fact table you can use

Running Total =
VAR CurrentDate =
    MAX ( 'Date'[Date] )
RETURN
    CALCULATE ( SUM ( 'Table'[Value] ), 'Date'[Date] <= CurrentDate )

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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

Top Solution Authors