Forum Discussion
Different Colors Datesbetween Measure
Hi Wedding55 ,
Are the current data and the forecast data from the same column in the table?
If yes, we can create a calculate column and two measures to meet your requirement.
1. Create a column to determine whether the current date belongs to the forecast month or the existing month.
column =
var _today_month = MONTH(TODAY())
var _date_month = MONTH('Table'[Date])
var _today_year = YEAR(TODAY())
var _date_year = YEAR('Table'[Date])
return
IF(
_today_month<_date_month&&_today_year>=_date_year,1,0)
2. Then we can create two measures, put them in Values.
Current value =
CALCULATE(SUM('Table'[value]),FILTER('Table','Table'[column]=0))
Forecast value =
CALCULATE(SUM('Table'[value]),FILTER('Table','Table'[column]=1))
If it doesn’t meet your requirement, could you please provide a mockup sample based on fake data?
It will be helpful if you can show us the exact expected result based on the tables.
Please upload your files to OneDrive For Business and share the link here. Please don't contain any Confidential Information or Real data in your reply.
Best regards,
Community Support Team _ zhenbw
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
BTW, pbix as attached.
Hi Wedding55 ,
How about the result after you follow the suggestions mentioned in my original post?
Could you please provide more details or expected result about it If it doesn't meet your requirement?
If you've fixed the issue on your own please kindly share your solution. If the above posts help, please kindly mark it as a solution to help others find it more quickly.
Best regards,
Community Support Team _ zhenbw
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.