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 Forum,
I have a dashboardpage about the weekly sales numbers of 2016 and 2017, - Clustered column chart.
Is it possible to show only the sales numbers 6 weeks before and 6 weeks after the current date?
Thanks.
Solved! Go to Solution.
Hi @Wout,
Suppose you add a [WeekNum] column on chart X-axis, please create measures similar to below:
currentWeek = WEEKNUM(TODAY()) flag = IF ( [currentWeek] - MAX ( WeeklySales[WeekNum] ) <= 6 && [currentWeek] - MAX ( WeeklySales[WeekNum] ) >= -6, 1, 0 )
Select the clustered column chart, add above measure [flag] into Visual Level filter.
Best regards,
Yuliana Gu
Hi @Wout,
Suppose you add a [WeekNum] column on chart X-axis, please create measures similar to below:
currentWeek = WEEKNUM(TODAY()) flag = IF ( [currentWeek] - MAX ( WeeklySales[WeekNum] ) <= 6 && [currentWeek] - MAX ( WeeklySales[WeekNum] ) >= -6, 1, 0 )
Select the clustered column chart, add above measure [flag] into Visual Level filter.
Best regards,
Yuliana Gu
Thanks! It works!?
Do you also know what happens when it's week 48+ for example
Hi @Wout,
The week number showed on X-axis will be dynamically changed when week num is over 48. It always shows the sales numbers 6 weeks before and 6 weeks after the current date.
Regards,
Yuliana Gu
Yes, by creating two columns that will return the weeks before and after your current week.
Can you please share the PBIX?
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 |
---|---|
148 | |
111 | |
93 | |
84 | |
66 |