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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
Anonymous
Not applicable

No date hierarchy after group by.

After I do a group by and a table generated by group by my date column no has a hierarchy.

dyakoubek_0-1608661853051.png

LA_Grouped = GROUPBY(LA_Shifts_Grouped, LA_Shifts_Grouped[Driver], LA_Shifts_Grouped[Date], "Moves", MAXX(CURRENTGROUP(),LA_Shifts_Grouped[Moves]))
 
LA_Shifts_Grouped = GROUPBY('LA Shifts','LA Shifts'[Driver #],'LA Shifts'[Date],'LA Shifts'[Shift],"Moves",COUNTAX(CURRENTGROUP(), 'LA Shifts'[Driver #]))
 
 

 

1 ACCEPTED SOLUTION
v-yingjl
Community Support
Community Support

Hi @Anonymous ,

If your table which is used in the GROUPBY() function has any relationship with any others tables in the report, the new table will not have the date hierarchy.

re.png1.png

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yingjl
Community Support
Community Support

Hi @Anonymous ,

If your table which is used in the GROUPBY() function has any relationship with any others tables in the report, the new table will not have the date hierarchy.

re.png1.png

 

Best Regards,
Community Support Team _ Yingjie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@Anonymous ,These are the reasons Date Hierarchy can be missing
https://community.powerbi.com/t5/Desktop/Date-Hierarchy-Doesn-t-show/td-p/525460
https://community.powerbi.com/t5/Desktop/Date-hierarchy-not-available/td-p/438804
https://community.powerbi.com/t5/Desktop/Lost-Missing-Date-Hierarchy/td-p/421045

 

You can create a custom hierarchy if needed

https://www.tutorialgateway.org/create-hierarchy-in-power-bi/
https://www.youtube.com/watch?v=x6vXVJZ_eTY

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here
AllisonKennedy
Super User
Super User

@dyakoubek The built-in date hierarchy also disappears with relationships, but I always turn it off for my reports and use my own date table. It gives you more flexibility to create your own custom hierarchies exactly as you want.

Do you have a dating board? https://excelwithallison.blogspot.com/2020/04/dimdate-what-why-and-how.html

Here's how to create your own hierarchy: https://www.youtube.com/watch?v=1Y0T_KkeWyQ


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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