LOOKUP & COMBINE

ekhawaja

Board Regular
Joined
Dec 16, 2018
Messages
63
Office Version
  1. 365
So I am looking for a formula for column"result" that looks up the value from LOOKUP in DATA1, and if the value is repeated in DATA1, the result should show both values of DATA2 "concatenated" (separated by comma ",".).....see table below:

I have data in the range of 1000s that I will be running this against. If no value is found, result should show blank. Thanks in advance!

DATA1DATA2LOOKUPRESULT
54-PX-142JAY51-PX-370AFZ
71-PX-614BALI41-PX-156
71-PX-132BRIA54-PX-142JAY,JAY,KAY
42-SV-280MIA30-PX-140
54-PX-142JAY42-SV-280MIA
71-PX-132BRIO
51-PX-370AFZ
54-PX-142KAY
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
Try:

Book1
ABCDE
1
2DATA1DATA2LOOKUPRESULT
354-PX-142JAY51-PX-370AFZ
471-PX-614BALI41-PX-156 
571-PX-132BRIA54-PX-142JAY,JAY,KAY
642-SV-280MIA30-PX-140 
754-PX-142JAY42-SV-280MIA
871-PX-132BRIO
951-PX-370AFZ
1054-PX-142KAY
Sheet3
Cell Formulas
RangeFormula
E3:E7E3=TEXTJOIN(",",1,FILTER(B$3:B$10,A$3:A$10=D3,""))
 
Upvote 0
Solution

Forum statistics

Threads
1,223,214
Messages
6,170,771
Members
452,353
Latest member
strainu

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