Forum Discussion
Date hierarchy for Week
- 1 year ago
Anonymous
you need to create a week calculated column in your date table. ( either end of week, either start of week , either W conatenated with the week number ) .
then you can simply add this week column in your hierarchy . ( the week column can be created in powr query ).
honestly i dont memorize the way it can be created, but you can simply ask chatgpt or any other Ai chat tool, and it willl write the code for you . ( Note here, that you should not always rely on Ai tools , but for this specific need that would be fine ) .
if you dont have a date table, i would also recommend to create one . and then link your date table to your fact table.
All in One: Script to Create Calendar Table or Date Dimension using DAX in Power BI - RADACAD
Note :
base on the screenshot, i assume that you are using the auto/date time from power bi .if that so, i would recommend to turn off that options . ( this can be turned off from the options of power bi .
article for reference: Automatic time intelligence in Power BI - SQLBI
hope that helps you out with your problem .
- 1 year ago
Hi Anonymous ,
Thanks for reaching out to the Microsoft fabric community forum.
MasonMA , Daniel29195 , pallavi_r ,
Thanks for your prompt response.
I’ve implemented the Date hierarchy for the Week level and uploaded a sample PBIX file for your review. Kindly take a look and let me know if it’s working as expected on your end.
Looking forward to your feedback.
If this post helped resolve your issue, please consider the Accepted Solution. This not only acknowledges the support provided but also helps other community members find relevant solutions more easily.
We appreciate your engagement and thank you for being an active part of the community.
Best regards,
LakshmiNarayana
Anonymous
you need to create a week calculated column in your date table. ( either end of week, either start of week , either W conatenated with the week number ) .
then you can simply add this week column in your hierarchy . ( the week column can be created in powr query ).
honestly i dont memorize the way it can be created, but you can simply ask chatgpt or any other Ai chat tool, and it willl write the code for you . ( Note here, that you should not always rely on Ai tools , but for this specific need that would be fine ) .
if you dont have a date table, i would also recommend to create one . and then link your date table to your fact table.
All in One: Script to Create Calendar Table or Date Dimension using DAX in Power BI - RADACAD
Note :
base on the screenshot, i assume that you are using the auto/date time from power bi .
if that so, i would recommend to turn off that options . ( this can be turned off from the options of power bi .
article for reference: Automatic time intelligence in Power BI - SQLBI
hope that helps you out with your problem .