Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Need help connecting Date table to Fact Table

 

I am a beginner learning power bi and I need help connecting my date table which was generated using calenderautofunction to my fact table which is the Order Table. Whenever i link the date with creation date with my date table i get an error but when i link the date with order date i don't get any error but it still doesn't function correctly. 

  • Hi Anonymous 

    What about inserting a new calendar table using the "calendar" function and then linking it with the date column in the 'Order Table'?  

     

    The dax formula below will generate a calendar table based on the minimum and maximum date in your fact table.

    If you needed year, month, quarter, columns added, you can use "addcolumns" at the beginning like shown in an example below.

     

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Thank you so much! I also observed that the date format didn't match. After implementing your suggestion and creating the new table, I converted the date format to display only the date and not date/time. Additionally, I transformed the "ordered date" and "creation date"  columns in the order table to date-only format not date/time.

  • Hi Anonymous 

    What about inserting a new calendar table using the "calendar" function and then linking it with the date column in the 'Order Table'?  

     

    The dax formula below will generate a calendar table based on the minimum and maximum date in your fact table.

    If you needed year, month, quarter, columns added, you can use "addcolumns" at the beginning like shown in an example below.