V-Lookup in a cell with more than one value present

Theemeadelis

New Member
Joined
Jul 10, 2023
Messages
20
Office Version
  1. 365
Platform
  1. Windows
I am in need of a formula which will search for a specific value in a column of cells that may contain more than one value in each cell.

e.g.

ABCDEF
1ROLERESULTROLERESULT
2897BONUS563, 897BONUS
3167#N/A
4897BONUS
5637, 598, 897BONUS
6324, 874#N/A
7162#N/A
8897BONUS
9354#N/A

I would be entering the formula in column F for it to check for every occurrence of the value "897" (B2), and for each occurrence of the B2 value "897" in column E, it would return the value from cell C2 "Bonus" in column E.

Is this possible with VLook-Up, or a different type of look-up formula?
 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
How would this work if there was a role and result in B3:C3 that had a role of 563? Trying to figure out what you are looking for
 
Upvote 0
How would this work if there was a role and result in B3:C3 that had a role of 563? Trying to figure out what you are looking for
ABCDEF
1ROLERESULTROLERESULT
2897BONUS563, 897BONUS, TRIPLE
3563TRIPLE167#N/A
4897BONUS
5637, 598, 897BONUS
6324, 874#N/A
7162#N/A
8897BONUS
9354#N/A

If there was a value in B3 of 563 with a corresponding result of TRIPLE in C3, ideally it would return the value as now showing in F2 - or something similar.
 
Upvote 0
How about
Fluff.xlsm
ABCDE
1ROLERESULTROLERESULT
2897BONUS563, 897TRIPLE, BONUS
3563TRIPLE167 
4897BONUS
5637, 598, 897BONUS
6324, 874 
7162 
8897BONUS
9354 
Data
Cell Formulas
RangeFormula
E2:E9E2=TEXTJOIN(", ",,XLOOKUP(--TRIM(TEXTSPLIT(D2,",")),$A$2:$A$5,$B$2:$B$5,""))
 
Upvote 0
How about
Fluff.xlsm
ABCDE
1ROLERESULTROLERESULT
2897BONUS563, 897TRIPLE, BONUS
3563TRIPLE167 
4897BONUS
5637, 598, 897BONUS
6324, 874 
7162 
8897BONUS
9354 
Data
Cell Formulas
RangeFormula
E2:E9E2=TEXTJOIN(", ",,XLOOKUP(--TRIM(TEXTSPLIT(D2,",")),$A$2:$A$5,$B$2:$B$5,""))
I'm struggling to get this to work - with it returning a Value error

1706719900960.png
 
Upvote 0
How are the values in A2:A3 formatted? are they text values or number values?
 
Upvote 0
What happens if you remove the double unary (ie --) ?
 
Upvote 0

Forum statistics

Threads
1,223,880
Messages
6,175,155
Members
452,615
Latest member
bogeys2birdies

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