Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi,
I currently have a visual for MTD sales, where after the latest daily sales, the rest of the day for the month flatlines, with no new sales. How can I stop this so that the MTD sales stops as the latest day.
I have used the following with no success:
MTD_Sales = if(ISBLANK(TOTALMTD(SUM(All_Sales[Total_Sales]), All_Sales[All_Invoice_Date].[Date])),BLANK(),CALCULATE(
TOTALMTD(SUM(All_Sales[Total_Sales]),All_Sales[All_Invoice_Date].[Date],FILTER(
ALLSELECTED(All_Sales[Invoice Date].[Date]),
ISONORAFTER(All_Sales[Invoice Date].[Date], MAX(All_Sales[Invoice Date].[Date]), DESC)
))))
&
MTD_Sales = TOTALMTD(SUM(All_Sales[Total_Sales]),All_Sales[All_Invoice_Date].[Date])
N.B. All_Sales[All_Invoice_Date] is aligned to the dates for the budgets and sales
Solved! Go to Solution.
Instead of ISONORAFTER(DESC) use DATESBETWEEN the MIN and MAX fact dates for each period.
Hi, I tried this by amending it to:
But the visual breaks and I get this error:
User | Count |
---|---|
85 | |
79 | |
64 | |
52 | |
46 |
User | Count |
---|---|
101 | |
44 | |
41 | |
39 | |
37 |