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.
Hi Gurus,
Hope this is not too hard to fix. 🙂 I'm using a Calendar table and used Date column as a filter in a report, but everytime I use the Months (Calendar), the latest month is not showing up (first screenshot). Also, when I use Months as a filter instead, it shows the latest month, but the date starts at 10/19/2017, not 10/1/2017, thus resulting to incorrect count in the views (screenshot 2).
Thanks,
Paul
Solved! Go to Solution.
Maybe you can try parameters. We can use power query functions to define some date parameters like below and use parameter to filter tables:
@Today: DateTime.LocalNow()
@OneYearEarlier: Date.AddYears(Date.From(DateTime.LocalNow()),-1)
Power Query M function reference:
https://msdn.microsoft.com/en-us/library/mt296606.aspx
Thanks,
Xi Jin.
For your first question, you can refer to this article: Use a relative date slicer and filter in Power BI Desktop. When selecting Months (Calendar), the visuals constrained would only show the complete calendar months. It also means since January 2018 is not a complete month for now. The Slicer cannot catch it when selecting Months (Calendar). And this is by design.
Then for your second question, if you are selecting Months. It also means you are doing something like the DATEDIFF() function, based on current date and get the day which is 3 months earlier. Current day is January 19, 2018, based on it the day 3 months earlier is October 19, 2017. It’s all right.
Thanks,
Xi Jin.
Ok, @v-xjiin-msft. got it. If it's Slicer's function by design then maybe the're nothing we can do so far. I'm still wondering if there's a better workaround we can use to capture the dates I'd like to select?
Maybe you can try parameters. We can use power query functions to define some date parameters like below and use parameter to filter tables:
@Today: DateTime.LocalNow()
@OneYearEarlier: Date.AddYears(Date.From(DateTime.LocalNow()),-1)
Power Query M function reference:
https://msdn.microsoft.com/en-us/library/mt296606.aspx
Thanks,
Xi Jin.
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 |
---|---|
97 | |
96 | |
81 | |
74 | |
66 |
User | Count |
---|---|
126 | |
106 | |
105 | |
86 | |
72 |