Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Solved! Go to Solution.
Hi,
Try this
MTD sales = CALCULATE([TotalSales],DATESBETWEEN(Calendar[Date],DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY()),1),DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY()),DAY(TODAY()))))
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi,
Try this measure for YTD sales
YTD sales = CALCULATE([TotalSales],DATESBETWEEN(Calendar[Date],MIN(Calendar[Date]),DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY()),DAY(TODAY()))))
Select 2017 in the slicer. The slicer should be built from the Calendar Table.
Works great
thank you Ashish
You are welcome. If my reply helped, please mark it as Answer.
of course Ashish just iam trying to calculate MTD with the same way can you help please ?
Hi,
I do not understand. Please clarify.
i would like to calculate MTD so if i move the year slicer to the previous years i will see the total month to date (totalsales) in the same day like today
Hi,
Try this
MTD sales = CALCULATE([TotalSales],DATESBETWEEN(Calendar[Date],DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY()),1),DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY()),DAY(TODAY()))))
well done ashish that works
thank you so much
You are welcome.
Hi ashish
i tried to calculate
last mounth MTD
MTD_Lm_TotalSales = calculate ([MTDtotalsales];PARALLELPERIOD('Calendar'[Date];-1;MONTH))
but it gives me the same results as MTD([TotalSales]
Hi,
Try this
LM MTD sales = CALCULATE([TotalSales],DATESBETWEEN(Calendar[Date],DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY())-1,1),DATE(YEAR(MIN(Calendar[Date])),MONTH(TODAY())-1,DAY(TODAY()))))
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |