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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
SK__
Regular Visitor

Unable to create a working slicer due to date hierarchy.

I have Two Tables each having a date column which is in long date format DD:MM:YY HH:MM:SS 

Before relationship between the two, both are having date hierarchies. 

 

Now, post creating date hierarchy, one of the tables is losing it's date hierarchies. 

 

When I insert a slicer with the date column. Then one of the visuals (who has the date hierarchy present) is responding properly to the slicer. But the other one (whose date hierarchy went missing) is going blank. 

 

I also tried to create a new table with just the dates and then made relationship with other two. But in that both the tables end up losing the date hierarchy and then not respond to the date slicer.

 

Is there any solution through which I can create a relationship between the tables and both the visuals will react to the same date slicer. 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @SK__ 

After testing, because your date contains time, so you need to extract the date first.

e.g Sample data 

vxinruzhumsft_0-1710465500292.png

1.Create a new column in the table

Column = 'Table'[Column1].[Date]

 2.then create the calendar table and create the relationship between the column created above the the date column calendar table.

Table 2 = CALENDAR(DATE(2023,11,1),TODAY())

vxinruzhumsft_1-1710465620228.png

3.Then put the date column of calendar table to the slicer, then it can work.

vxinruzhumsft_2-1710465661095.png

 

Best Regards!

Yolo Zhu

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

4 REPLIES 4
SK__
Regular Visitor

SK___0-1710414290459.png

I created this table and created a relationship with date of the other two tables. 

 

SK___1-1710414427041.pngSK___2-1710414447005.png

These are the formats of the dates.

 

Relationship is active.

 

Till the time I create a slicer everything is visible. But once I create a slicer for dates 

SK___3-1710414508024.png

like this and move the slicer. The visual stops responding and goes blank. 

 

I have even tried with the option 2 of auto data/time.

Anonymous
Not applicable

Hi @SK__ 

After testing, because your date contains time, so you need to extract the date first.

e.g Sample data 

vxinruzhumsft_0-1710465500292.png

1.Create a new column in the table

Column = 'Table'[Column1].[Date]

 2.then create the calendar table and create the relationship between the column created above the the date column calendar table.

Table 2 = CALENDAR(DATE(2023,11,1),TODAY())

vxinruzhumsft_1-1710465620228.png

3.Then put the date column of calendar table to the slicer, then it can work.

vxinruzhumsft_2-1710465661095.png

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thank you. It worked. 

Anonymous
Not applicable

Hi @SK__ 

The problem you mentionded that create date hierarchy, one of the tables is losing it's date hierarchies when thay have relationships, the structure is set up in such a way that when two tables have a relationship, only one table can have a hierarchy.

And after testing, when you have relationship among tables, it can work. Please refer to the following steps to check if your creation is right.

1.It is better that create a calendar table, then create a one-many relationhip between tables.

Sample table.

vxinruzhumsft_0-1710383040042.png

a.Create a calendar table

vxinruzhumsft_2-1710383081117.png

b.Create relationship between tables.

vxinruzhumsft_3-1710383150052.png

c.Put the date column of calendar table  to the slicer. and put the date field to a table visual for test. it should work.

Output

vxinruzhumsft_4-1710383263776.png

2. Or you can consider not to use the date hierarchies. Close it at the option setting.

vxinruzhumsft_6-1710383707087.png

 

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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