cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
hongjyan
Helper II
Helper II

what's the difference between 'table'[date] and 'table'[date].[Date]?

Hi, guys

I created a table via CalenderDate = CALENDAR(DATE(2019, 01, 01), DATE(2020, 12, 31))

 

then, create a column via Month = FORMAT(CalenderDate[CalenderDate], "yyyy-mm")
then create a measure named max1 via max1 = MAX(CalenderDate[CalenderDate])
then create a measure named max2 via max2 = MAX(CalenderDate[CalenderDate].[Date])
then use column:month as filter to get corresponding max1/max2.
Result is as following:
max.png
why? why filter doesn't apply on max2?
1 ACCEPTED SOLUTION
Mariusz
Community Champion
Community Champion

Hi @hongjyan 

 

Hopefully, this article will help you to understand what [Date].[Date] is 
https://www.sqlbi.com/articles/automatic-time-intelligence-in-power-bi/

 

In your example, max2 is returning a max of all dates in automatic date/time table as Month column is in another table that is not propagating the filter down to auto date table.

 

If you have a date dimension in your model best practice is to switch off automatic date/time and not use it.

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
LinkedIn

 

View solution in original post

1 REPLY 1
Mariusz
Community Champion
Community Champion

Hi @hongjyan 

 

Hopefully, this article will help you to understand what [Date].[Date] is 
https://www.sqlbi.com/articles/automatic-time-intelligence-in-power-bi/

 

In your example, max2 is returning a max of all dates in automatic date/time table as Month column is in another table that is not propagating the filter down to auto date table.

 

If you have a date dimension in your model best practice is to switch off automatic date/time and not use it.

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
LinkedIn

 

Helpful resources

Announcements
June 2022 update 768X460.jpg

Check it out!

Click here to read more about the June 2022 updates!

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Power BI Dev Camp Session 23 768x460.jpg

Check it Out!

Mark your calendars and join us on Thursday, June 30 at 11a PDT for a great session with Ted Pattison!

June 20 episode 7 with aka link 768x460.jpg

The Power BI Community Show

Join us on June 20 at 11 am PDT when Kim Manis shares the latest on Azure Synapse analytics, the Microsoft Intelligent Data Platform, and notable Power BI Updates from Microsoft Build 2022.

Top Solution Authors
Top Kudoed Authors