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

Get Fabric certified for FREE! Don't miss your chance! Learn more

Reply
Jayesh
Regular Visitor

Cumulative Running total Dates missing

Hi Team,

 

i have one defect table and one Date dim table. The defect table have 2 dates creation date and resolution date. I have created 2 relationship between date dim and defect table with creation date and date dim as active relationship. i am trying to achieve the running total using date dim date and the other two dates, but not getting expected results, please refere the screenshot and help me here.

 

Jayesh_0-1730323385125.png

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi  @Jayesh ,

 

Here are the steps you can follow:

1. Create measure.

Total Defects Measure =
SUMX(
    FILTER(ALL('defect table'),
    'defect table'[creation date]<=MAX('Date dim table'[creation date])),[Total Defects])
Total Open Defects Measure =
SUMX(
    FILTER(ALL('defect table'),
    'defect table'[creation date]<=MAX('Date dim table'[creation date])),[Total Open Defects])
Total Resolved Defects Measure =
var _table1=
ADDCOLUMNS(
    'defect table',"Date",
    MAXX(
        FILTER(ALL('defect table'),
       'defect table'[creation date]<=EARLIER('defect table'[resolution date])),
        [creation date]))
var _table2=
ADDCOLUMNS(
    _table1,"Value",SUMX(FILTER(_table1,[Date]=EARLIER([Date])),[Total Resolved Defects]))
return
SUMX(
    FILTER(_table2,[Date]<=MAX('Date dim table'[creation date])),[Value])

2. Result:

vyangliumsft_0-1730343213298.png

 

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi  @Jayesh ,

 

Here are the steps you can follow:

1. Create measure.

Total Defects Measure =
SUMX(
    FILTER(ALL('defect table'),
    'defect table'[creation date]<=MAX('Date dim table'[creation date])),[Total Defects])
Total Open Defects Measure =
SUMX(
    FILTER(ALL('defect table'),
    'defect table'[creation date]<=MAX('Date dim table'[creation date])),[Total Open Defects])
Total Resolved Defects Measure =
var _table1=
ADDCOLUMNS(
    'defect table',"Date",
    MAXX(
        FILTER(ALL('defect table'),
       'defect table'[creation date]<=EARLIER('defect table'[resolution date])),
        [creation date]))
var _table2=
ADDCOLUMNS(
    _table1,"Value",SUMX(FILTER(_table1,[Date]=EARLIER([Date])),[Total Resolved Defects]))
return
SUMX(
    FILTER(_table2,[Date]<=MAX('Date dim table'[creation date])),[Value])

2. Result:

vyangliumsft_0-1730343213298.png

 

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

Check out the February 2026 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.