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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
RedHare
Frequent Visitor

Creating a relationship between Date table and Key table

Hello all, I'm fairly new to Power BI and would appreciate some assistence with creating a relationship between my date table and a key table. Below is a screen shot of my data model:

RedHare_0-1645112813094.png

 

I currently don't have a relationship between my date table and the Query1 table because I would only have specific to the dates that are for whatever date column I've added to Query1. Since I have many different date column from various tables, I'm not sure how to create a relationship between all of those date columns and my date table - assuming I'd use the date column from the date table as my unique key to join on. I've looked up various tutorials on creating a date table, and it appears I need a foreign date key on the Query1 table which I could then use to connect everything. However, I'm not sure if that solution would solve my problem. 

 

I hope this is enough info, but if not please let me know and I'll be happy to show more.

 

Thanks!

1 ACCEPTED SOLUTION
aj1973
Community Champion
Community Champion

Hi @RedHare 

You can only create one Active relationship between your date tabel and Query1. However you can add Inative relationships to the reste of date columns in Query1 and then use DAX to do calculations as you wish.

Regards
Amine Jerbi

If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook

View solution in original post

3 REPLIES 3
aj1973
Community Champion
Community Champion

Hi @RedHare 

You can only create one Active relationship between your date tabel and Query1. However you can add Inative relationships to the reste of date columns in Query1 and then use DAX to do calculations as you wish.

Regards
Amine Jerbi

If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook

Yeah, I'm aware of only being able to have 1 active relationship, but I was hoping to not have to write much DAX. Any ideas on how I could do this?

aj1973
Community Champion
Community Champion

Create many date tables then..

Regards
Amine Jerbi

If I answered your question, please mark this thread as accepted
and you can follow me on
My Website, LinkedIn and Facebook

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Carousel June 2024

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

2
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.