Vookups and index match not working on text in a cell derived from concatenation formula

richardcarter

Board Regular
Joined
Dec 10, 2003
Messages
77
I am trying to do a VLOOKUP (or an INDEX/MATCH) on cell A1 on Sheet 1 which contains the words 'Green Apples'. However the words 'Green Apples' in this cell have been derived from text concatenation so although the cell shows the words 'Green Apples', the cell actually contains the formula:

=Sheet2!$A$1&" "&"Apples" (so the word 'Green' is coming from cell A1 on Sheet 2).

What I am trying to do now is another vlookup based on Cell A1 Sheet 1 but the following formula throws up #N/A (and the same result if I use index/match instead). However, if I take out the concatenated formula and just type in the words 'Green Apples' into cell A1, then the formula works fine.

=VLOOKUP("Green Apples",Sheet1!A1:C20,3,FALSE)

Suggestions appreciated!
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
Check for any spaces befor or after the "Green" word or try if this helps:
=TRIM(Sheet2!$A$1)&" "&"Apples"
 
Upvote 0
Solved - Thank you! I did have spaces in there.... but I put them in their deliberately as I need them for other referencing... but I think I can tweak it using your TRIM suggestion and cutting off characters using LEFT(x,x) RIGHT(x,x) trim functions.
 
Upvote 0

Forum statistics

Threads
1,215,694
Messages
6,126,255
Members
449,306
Latest member
RealNinetyThree

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top