Selecting a Keyword
One way...
Create a 2 column lookup table like this:
apple...fruit
strawberry...fruit
banana...fruit
tomatoe...vegetable
carrot...vegetable
onion...vegetable
Assume that table is in the range D1:E6
Then use this formula in column B:
=IF(COUNTIF(D$1:D$6,A1),VLOOKUP(A1,D$1:E$6,2,0),IF (A1<"","Beef",""))
--
Biff
Microsoft Excel MVP
"Gmata" wrote in message
...
Hello guy i am trying to come up with a formula but i have no idea how i
need
some help from the experts.
I have two columns,
1 contains information and the other one is empty where the formula is
going
to be called "product type"
So what i need is:
If column A contains the word: Apple, strawberry, banana. Column B should
be = Fruits
If column A contains: tomatoe, carrot, onion B = Vegetable
If columb A contains anything other than: Apple, strawberry,
banana,tomatoe,
carrot, onion. B= Beef
Is it possible to create this formula?
Thanks
|