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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
littlemojopuppy
Community Champion
Community Champion

"Can't create relationship between two columns with incompatible data types"?

Hi -

 

This is...odd.  Relationship between my date table and another is producing an error "Can't create relationship between two columns with incompatible data types".  Seems like a straightforward solution: fix the data types so they match...

Image 1.png

 

But...after looking at both sides of the relationship, they do match (both are integer)

Image 3.pngImage 2.png

Has anyone ever encountered this before???

 

Both tables are based off views.  One (Dim_Date) is simply pull data from the source with no transformation at all.  The second view involves some manipulation of the underlying data to transform the data from the source.  Specifically:

  1. Underlying data is a text date field in the format of YYYY-MM
  2. Concatenate
    • LEFT() four characters for the year,
    • Then RIGHT() two characters for month
    • Then "01" for the day.
  3. Convert that result into an integer data type.

These transformations are done in the view, not in Power Query.  Only thing I can think of is that the data that comes into the tabular model isn't valid and is causing errors.  But I've reviewed output from the views and data coming into model, and everything seems ok.

 

Anyone ever encounter something like this before?

2 REPLIES 2
littlemojopuppy
Community Champion
Community Champion

Community Admins - 

 

This actually isn't solved.  The above post was nothing more than testing/proving that the two fields in question are the same data type.  Maybe this is a bug in Tabular Editor?  Who knows?  But it's definitely not solved.

 

If there's a closed / not solved status, feel free to change it to that...

littlemojopuppy
Community Champion
Community Champion

As a test, pulled the two views into a brand new pbix file.  Relationship created with no issues...

ab5f85b0-b8e5-4c46-9e64-0e03f991c1a9.png

 

 

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.