Forum Discussion
Not able to make a relationship between tables through date column
I have Tables "Opportunity" and "Targets", there is no relationship between these 2 columns and when I try to join them using their date columns I get the Cardinality error.
So what I did is that I created a new table ( Date ) and added a calculated date column of date in it. Now when I try to create a relationship of the "Date" table with "Targets" or "Opportunities", the relationship is created but it does not work when I use the date column in a slicer it shows blank data. Also when the relationship is created the type of "Targets" and "Opportunities" date column changes to "Text".
Please help
- Anonymous2 years ago
Hi Anonymous ,
Based on my testing, Please try the following methods:
Create the Date table.
Table = CALENDAR(DATE(2024, 1, 1), DATE(2024, 4,1))Select manage relationships
Create the relationship between Date Table and Targets table.
The result is shown below.
You can view the following document to learn information about creating a relationship.
Create and manage relationships in Power BI Desktop - Power BI | Microsoft Learn
Best Regards,
Wisdom Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- Wilson_
Memorable Member
Can you please share a sample pbix file? (If you don't know how, please check the pinned thread in the forum.) It would make debugging your issue easier. 🙂
- AnonymousNot applicable
Hi Anonymous ,
Based on my testing, Please try the following methods:
Create the Date table.
Table = CALENDAR(DATE(2024, 1, 1), DATE(2024, 4,1))Select manage relationships
Create the relationship between Date Table and Targets table.
The result is shown below.
You can view the following document to learn information about creating a relationship.
Create and manage relationships in Power BI Desktop - Power BI | Microsoft Learn
Best Regards,
Wisdom Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.