cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Left joins generate duplicate values issue

Hello,

 

I am trying to join two tables with a left join UNITS (left table) and TENANT(right table) tables. After the join I am extending the values I want to add in my table and they extend with no problem. The problem is that for some reason new rows are being added in my table and I receive an error message for duplicate ID (primary key) values as a result of the raws addition. Please see a screenshot of this message below.

index issue.PNG

 

Can you please support with this? 

 

Many thanks,

MariosChr90

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User IV
Super User IV

Re: Left joins generate duplicate values issue

The issue is that you are likely extending a column that then generates a duplicate row for 99. So, you can imagine how this might happen. When you join the tables, you are aggregating multiple rows from TENANTS for "99" to a single row. But, when you expand the aggregation, you end up with multiple rows of 99 and hence you are getting an issue with your relationship.


---------------------------------------

Putting square pegs in round holes since 1972.

I have a NEW book! 
DAX Cookbook from Packt
Over 120 DAX Recipes!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

2 REPLIES 2
Highlighted
Super User IV
Super User IV

Re: Left joins generate duplicate values issue

The issue is that you are likely extending a column that then generates a duplicate row for 99. So, you can imagine how this might happen. When you join the tables, you are aggregating multiple rows from TENANTS for "99" to a single row. But, when you expand the aggregation, you end up with multiple rows of 99 and hence you are getting an issue with your relationship.


---------------------------------------

Putting square pegs in round holes since 1972.

I have a NEW book! 
DAX Cookbook from Packt
Over 120 DAX Recipes!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

Highlighted
Anonymous
Not applicable

Re: Left joins generate duplicate values issue

Yes I see, I have resolved the issue. I just remove manually the one duplicate value of '99'.

 

Many thanks for the support!

Helpful resources

Announcements
August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Upcoming Events

Upcoming Events

Wondering what events you could join or have an event to promote yourself? Check out our Upcoming Events.

Get Ready for Power BI Dev Camp

Get Ready for Power BI Dev Camp

We are thrilled to announce we will begin running a monthly webinar series named Power BI Dev Camp.

Top Solution Authors
Top Kudoed Authors