I have been trying several solutions suggested in diverse fora for a few hours but nothing seems to work (see here, for example). So this is my problem:

  • I have a long column of text strings which contain some keywords and lots of rubbish.
  • I would like to generate a new clean value in another column, depending on which one of the keywords were found in the first one.
  • I have a little table with the keywords/strings to be found and the desired return values.
  • I have tried nested IFs, but it becomes too complex and not flexible. I would prefer a function that relies on that table.
  • 1
    Adding some sample data to your question would probably be useful.
    – ale
    Feb 27 '18 at 18:29

Keyword table: Z1:Z4 Text strings: A:A


  • Worked like a charm :-) Thank you very much! This is sufficient to solve my problem. But in case I wanted an output value that is not exactly the keyword in Z1:Z4, but a corresponding term in Y1:Y4, how could I do that?
    – Mike
    Feb 28 '18 at 20:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.