How to match comma separated values in cell to a list? Help pls..

adiritz

New Member
Joined
Mar 19, 2015
Messages
10
For every number in Column A, I have a separate list. I would like to check if in next 4 rows, any number came from this list.

[TABLE="width: 500, align: left"]
<tbody>[TR]
[TD]COLUMN A[/TD]
[TD]COLUMN B[/TD]
[TD]COLUMN C[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]12,1,3,9,4[/TD]
[TD]TRUE[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]1,33,54,99,33[/TD]
[TD]FALSE[/TD]
[/TR]
[TR]
[TD]26[/TD]
[TD]45,76,88,1[/TD]
[TD]FALSE[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]12,1,3,9,4[/TD]
[TD]FALSE[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]2,51,31,45,67[/TD]
[TD]TRUE[/TD]
[/TR]
[TR]
[TD]31[/TD]
[TD]22,17,19,9[/TD]
[TD]TRUE[/TD]
[/TR]
[TR]
[TD]17[/TD]
[TD]22,25,89,99[/TD]
[TD]FALSE[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]2,51,23,45,67[/TD]
[TD]FALSE[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]1,3,45,67[/TD]
[TD]FALSE[/TD]
[/TR]
</tbody>[/TABLE]
















Please advice how to calculate this. I tried Match and Find, not getting any success.
 
Hi,

I don't understand how you calculate the TRUE/FALSE column in your example.
In line 2, you want to check for value 1 in the next four rows. I think there is 1 in the row below (last value) and yet you mark 'FALSE' is a result?
 
Upvote 0
Maybe this formula in C1 copied down
=SUMPRODUCT(--ISNUMBER(SEARCH(","&A2:A5&",",","&SUBSTITUTE(B1," ","")&",")))

Hope this helps

M.
 
Last edited:
Upvote 0

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