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
Anonymous
Not applicable

Not fetching detail from Calander table even after proper relationship

Hi Experts,

 

I have crated a Calendar table as below:

Calendar = ADDCOLUMNS(CALENDAR(DATE(2019,1,1),DATE(2021,12,31)),"WeekDay",WEEKDAY([Date],2))
 
And create many-to-one relationship from Main table 'TransactionLog' (TransactionDate) to this calendar table (Date ).
When I am created calculated column as below with RELATED() function under main table:
 
TxDate_Week = RELATED('Calendar'[WeekDay])
OR
TxDate_CalendarDate = RELATED( 'Calendar'[Date])
 
Its actually not working.. both columns are fetching blank value. and there is no error at all.
 
Can you suggest/hint where i can check further?
 
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @CNENFRNL , thanks for your response,

I got the resolution. It was giving error even when both columns were of datetime data type. One column from main table was having real time timestamp like '25/11/2020 18:30:00' and column from calendar table *created using DAX) was having fix timestamp for every date such as 25/11/2020 12:00:00 AM. hence it was not matching with each other.

Making both columns strictly 'Date' as datatype and format as 'd/m/yyyy' resolved the issue.

Thanks again for your response.

 

View solution in original post

2 REPLIES 2
CNENFRNL
Community Champion
Community Champion

Hi,  , did you verify if the format of 'TransactionLog'[TransactionDate] is Date instead of Text? All works well by my side,Screenshot 2020-11-24 105847.png


Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension!

DAX is simple, but NOT EASY!

Anonymous
Not applicable

Hi @CNENFRNL , thanks for your response,

I got the resolution. It was giving error even when both columns were of datetime data type. One column from main table was having real time timestamp like '25/11/2020 18:30:00' and column from calendar table *created using DAX) was having fix timestamp for every date such as 25/11/2020 12:00:00 AM. hence it was not matching with each other.

Making both columns strictly 'Date' as datatype and format as 'd/m/yyyy' resolved the issue.

Thanks again for your response.

 

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.

Top Solution Authors
Top Kudoed Authors