Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
vopatel
Frequent Visitor

Grouping by Week Starting Date as Monday and filtering by Year, Month, Week and Date

I have an Oracle database table which has a column with datatype date. I would like a clustered column chart where I can drilldown by year, quarter, month, week and day. When I drop a date column of my table in X axes, I can only see default filters for year, quarter, month and day, so I created new group on the date column with size of bin as 7 and added on shared axis as shown in screenshot. This way I am able to drill down by week fine, but the problem is week starts on Sunday, while I need week to start on Monday.  See the screenshot https://pasteboard.co/GS4reUt.png

 

Not sure how I can do that.

 

 

3 REPLIES 3
Anonymous
Not applicable

1. Have you made sure week AND day in your DimDate Query passes the statement number for starting on Monday i.e:
"WeekNum"; WEEKNUM([Date];2);
"WeekDay"; WEEKDAY([Date];2);

2. Next check your Table in Power BI and see if the Day name "Monday" is Sorted by the numeric value of WeekDay "1".

BI forum 1.jpg

3. Lastly The Hierchy should look like this for drilldown to work properly (I'm guessing Saturday and Sunday may present a problem due to NULL values if you want to include them):
BI forum 2.jpg


Hope you find a solution here.
Please upvote or mark as solution so I can get my 1st Badge If I helped you!

Cheers!

v-chuncz-msft
Community Support
Community Support

@vopatel,

 

You may create a calculated column instead.

Week =
Query1[ORDER_DATE] - WEEKDAY ( Query1[ORDER_DATE], 3 )
Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Didnt work as expected. When I drill down to week, I see numbers jumping by 5 on X axes. See https://pasteboard.co/GSofr0Y.png

 

I would like to see week start date(Monday) on X axes.

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.