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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Mai_Nashaat
Helper II
Helper II

Merging Tables

Hi guys,

 

I need to merge two tables on three columns ; date, van code and product

type of each column is date, text and text respectively. 

when trying to merge them column date and product matches successfully but van code doesn't although the column in both tables has the same values, data type and name and neither of them has empty rows.

 

any help please why this happens and what to do

@jimmy @Rocco  @edhans 

thanks in advance,

Mai

1 ACCEPTED SOLUTION
edhans
Super User
Super User

There is something wrong with your data. In Power Query I've never had an issue merging on 3+ columns when the data is the same.

 

If the van code is text, see if you can TRIM it first, or perhaps CLEAN it. TRIM will remove any trailing spaces. Some text fields in databases will pad it with spaces if the actual value is shorter than the field setting. If that doesn't work, then use CLEAN. It will remove other characters, like the non-printing code 160 which looks like a space (char 32) but isn't.

Short of that, you'll need to post some of our source data so we can help troubleshoot further.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

1 REPLY 1
edhans
Super User
Super User

There is something wrong with your data. In Power Query I've never had an issue merging on 3+ columns when the data is the same.

 

If the van code is text, see if you can TRIM it first, or perhaps CLEAN it. TRIM will remove any trailing spaces. Some text fields in databases will pad it with spaces if the actual value is shorter than the field setting. If that doesn't work, then use CLEAN. It will remove other characters, like the non-printing code 160 which looks like a space (char 32) but isn't.

Short of that, you'll need to post some of our source data so we can help troubleshoot further.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors
Top Kudoed Authors