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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
LW_777
New Member

Merging Tables to Look-Up but Returning Null

Hi There,
I am using the merge query function to look-up values in another table (its product item numbers, therefore numbers and text) - trying to return the generic model numbers to help create a unique key between tables.  I have checked the data between the tables is in the same format (text) and there are no additional spaces/characters in either of the columns of data, yet Power Query is returning null.  Just doing a quick sample of the data in Excel and Excel returns true for an exact match.

Anyone have any other hints or ideas as to how I can resolve this please? 
My BI knowldge is exceptionally basic right now and trying to force myself to use BI given the size of data involved as I would always use Excel as standard.
Thank you.

LW_777_0-1674642006561.png

 

1 ACCEPTED SOLUTION
LW_777
New Member

Hi,

Thank you for your reply.

Both fields are upper text and numbers so it's not this causing the issue. 

In the end my manager my manager found the solution.  There was indeed spaces in one of the fields that didn't show when exporting to Excel or as text.  We performed the following steps to clean the data in order for the merge query to work:

Whilst in transform mode (Power Query),

Right click on the column to clean - select 'Replace Values'

LW_777_0-1674661185421.png

 

In 'Value To Find' put a single space (therefore cannot see it).

In 'Replace With', leave this blank / nothing

Click ok.

View solution in original post

3 REPLIES 3
LW_777
New Member

Hi,

Thank you for your reply.

Both fields are upper text and numbers so it's not this causing the issue. 

In the end my manager my manager found the solution.  There was indeed spaces in one of the fields that didn't show when exporting to Excel or as text.  We performed the following steps to clean the data in order for the merge query to work:

Whilst in transform mode (Power Query),

Right click on the column to clean - select 'Replace Values'

LW_777_0-1674661185421.png

 

In 'Value To Find' put a single space (therefore cannot see it).

In 'Replace With', leave this blank / nothing

Click ok.

BA_Pete
Super User
Super User

Hi @LW_777 ,

 

Have you also checked capitalisation? Power Query is entirely case-sensitive.

Try running Text.Upper on both [Item Number] and [ItemNum] before the merge.

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




Thank you Pete, it wasn't case sensitivity as all the product IDs are upper case and numbers.
Thak you for replying though.  Appreciate your time.  My manager tried a solution that work per my reply posted.

Laura

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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