Searching String Text for several if-than responses

Underdog12

New Member
Joined
Sep 21, 2022
Messages
5
Hi Everyone,

I keep messing this up and I'm sure its a simple mistake,,,,

I want to be able to search column d and have the response in column e

If d2 contains Strawberries, then Strawberries, if it contains Boat, then Boat, if Turkey, then Turkey -

IDLocationRegionDescription
1Florida3Bananas Strawberries Cars Fox Pineapple
2Texas2Red Blue Stars Stripes Car Boat
3Florida9Boat Blue Red Car Pineapple
4New York12Turkey Cookie Grapes Florida
5California53Strawberries Goat Frog
6Texas4Car Boat Red Blue
7New York13Green Purple Jet Turkey

Thank you in advance
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Hi Everyone,

I keep messing this up and I'm sure its a simple mistake,,,,

I want to be able to search column d and have the response in column e

If d2 contains Strawberries, then Strawberries, if it contains Boat, then Boat, if Turkey, then Turkey -

IDLocationRegionDescription
1Florida3Bananas Strawberries Cars Fox Pineapple
2Texas2Red Blue Stars Stripes Car Boat
3Florida9Boat Blue Red Car Pineapple
4New York12Turkey Cookie Grapes Florida
5California53Strawberries Goat Frog
6Texas4Car Boat Red Blue
7New York13Green Purple Jet Turkey

Thank you in advance
Sorry - I forgot to say that I want the search to be done row by row - not as a whole.
 
Upvote 0
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

What happens if a cell contains 2 or more of the "words of interest"? Or is that not possible with your data?
 
Upvote 0

Forum statistics

Threads
1,214,819
Messages
6,121,739
Members
449,050
Latest member
excelknuckles

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