The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event! Join us in Stockholm, Sweden from September 24-27, 2024.
2-for-1 sale on June 20 only!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hi, I'm new on power bi and I was working on a weekly coverage report that shows the number of outlets visited per week. To do this I applied a filter to show outlets covered on the first week, second week, and so on. However I'm unable to show all that in the same visual, all I can do is show a visual for each week.
I would really appreciate if I found a way to sort this out. Thanks.
Solved! Go to Solution.
@Kaskazi_Network , you can create week in date table and plot that in visual
or can have measures for this week, last week etc
https://medium.com/@amitchandak.1978/power-bi-wtd-questions-time-intelligence-4-5-98c30fab69d3
https://community.powerbi.com/t5/Community-Blog/Week-Is-Not-So-Weak-WTD-Last-WTD-and-This-Week-vs-La...
This Week = CALCULATE(sum('order'[Qty]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])))
Last Week = CALCULATE(sum('order'[Qty]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])-1))
2nd Last Week = CALCULATE(sum('order'[Qty]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])-2))
Hi, @Kaskazi_Network
Based on your description, I created data to reproduce your scenario. The pbix file is attacehed in the end.
Table::
You may create a calculated column or a measure as below.
Calculated column:
YearWeeknum = YEAR('Table'[Date])*100+WEEKNUM('Table'[Date])
Measure:
Result = DISTINCTCOUNT('Table'[ID])
Result:
Best Regards
Allan
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Kaskazi_Network , you can create week in date table and plot that in visual
or can have measures for this week, last week etc
https://medium.com/@amitchandak.1978/power-bi-wtd-questions-time-intelligence-4-5-98c30fab69d3
https://community.powerbi.com/t5/Community-Blog/Week-Is-Not-So-Weak-WTD-Last-WTD-and-This-Week-vs-La...
This Week = CALCULATE(sum('order'[Qty]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])))
Last Week = CALCULATE(sum('order'[Qty]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])-1))
2nd Last Week = CALCULATE(sum('order'[Qty]), FILTER(ALL('Date'),'Date'[Week Rank]=max('Date'[Week Rank])-2))
You need to create a calendar table
-https://radacad.com/create-a-date-dimension-in-power-bi-in-4-steps-step-1-calendar-columns
- Join this Calendar table with your table on Dates
- Mark Calendar table as "Date Table"
- Use Week from Calendar table to view weekly data.
Proud to be a Super User!
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 June 2024 Power BI update to learn about new features.
User | Count |
---|---|
98 | |
94 | |
87 | |
70 | |
65 |
User | Count |
---|---|
244 | |
127 | |
119 | |
81 | |
78 |