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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Priya2007
Frequent Visitor

Rolling month

Hi ,

I am using below formula to count Calculated_required_dates by 12 month rolling

TTM_sales3 =
VAR Currentdate = EOMONTH(Max ('Date'[CLOSED_DATE]),0)
var PreviousDate = EDATE ( EOMONTH (Currentdate, -1 ), -12 ) +1
VAR Result = CALCULATE (count('Work Delivery'[Calculated_REQUIRED_DATE]), Filter ('Work Delivery',MAX('Work Delivery'[CLOSED_DATE])>=PREVIOUSDATE && MAX('Work Delivery'[CLOSED_DATE])<= CURRENTDATE))
RETURN Result
I am getting the exact result but total is missing.Total is missingTotal is missing
1 ACCEPTED SOLUTION
v-qiuyu-msft
Community Support
Community Support

Hi @Priya2007

 

Assume the [Month_Closed] in the table 'Work Delivery', you can create a measure like below: 

 

MeasureTotal=

VAR __table = SUMMARIZE('Work Delivery',[Month_Closed],"__value",[TTM_sales3])
RETURN
IF(HASONEVALUE('Work Delivery'[Month_Closed]),[TTM_sales3],SUMX(__table,[__value]))

 

Reference: 

https://community.powerbi.com/t5/Quick-Measures-Gallery/Measure-Totals-The-Final-Word/m-p/547907

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
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
v-qiuyu-msft
Community Support
Community Support

Hi @Priya2007

 

Assume the [Month_Closed] in the table 'Work Delivery', you can create a measure like below: 

 

MeasureTotal=

VAR __table = SUMMARIZE('Work Delivery',[Month_Closed],"__value",[TTM_sales3])
RETURN
IF(HASONEVALUE('Work Delivery'[Month_Closed]),[TTM_sales3],SUMX(__table,[__value]))

 

Reference: 

https://community.powerbi.com/t5/Quick-Measures-Gallery/Measure-Totals-The-Final-Word/m-p/547907

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

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.