The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hi There ;
I have an excel data as below , basicly material , delivery date , and quantities , imagine that i am creating a table visiual and adding a filter pane on visiual filter as "Delivery Date " = related date and this month , table dinamicly shows this month's quantities.
So then i remove material and delivery date headers from table so table shows totaly 200+ 300 + 700 = 1200 Quantities on table , but i would like to create two measure ;
Thanks in advance
Solved! Go to Solution.
@erhan_79 , I think first one cumulative
Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(all('Date'),'Date'[date] <=max('Date'[date])))
Second one can be
MTD Today =
var _min = eomonth(today(),-1)+1
var _max = today()
return
CALCULATE([Net], FILTER('Date','Date'[Date] >=_min && 'Date'[Date] <= _max))
MTD Yesterday =
var _max = today() -1
var _min = eomonth(_max,-1)+1
return CALCULATE([Net], FILTER('Date','Date'[Date] >=_min && 'Date'[Date] <= _max))
hi @amitchandak ;
Firts measure ok thanks but secaond measure i need dynamic , i mean ;
if today is 30 december , system will calculate between 15 december and 30 december
if today is 25 december , system will calculate between 10 december and 25 december
if today is 13 december , system will calculate between 28 november and 13 december
always dinamicly will calculate the quantities between today and 15 days before then today
i hope it is clear
@erhan_79 , I think first one cumulative
Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(all('Date'),'Date'[date] <=max('Date'[date])))
Second one can be
MTD Today =
var _min = eomonth(today(),-1)+1
var _max = today()
return
CALCULATE([Net], FILTER('Date','Date'[Date] >=_min && 'Date'[Date] <= _max))
MTD Yesterday =
var _max = today() -1
var _min = eomonth(_max,-1)+1
return CALCULATE([Net], FILTER('Date','Date'[Date] >=_min && 'Date'[Date] <= _max))
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
122 | |
87 | |
75 | |
55 | |
45 |
User | Count |
---|---|
135 | |
121 | |
77 | |
65 | |
64 |