+ Reply to Thread
Results 1 to 11 of 11

URGENT: How to match a text cell with a list of texts and return a desired string of text

  1. #1
    Registered User
    Join Date
    09-16-2014
    Location
    Boston, MA
    MS-Off Ver
    2013
    Posts
    10

    URGENT: How to match a text cell with a list of texts and return a desired string of text

    Hi all, I have been trying to solve this all day without success. Hopefully some one can help me out, I highly appreciate it!

    ExcelHelp.PNG

    Please refer to the picture or excel file.

    Problem: I need a formula in the yellow area where it can look at each grocery bag, and satisfy the condition below:

    Condition: If the _#B_#B (or) KAPOW appears in Grocery Bag 1 , then it is Juicy.
    If the _#B_#B (or) KAPOW appears in Grocery Bag 2, then it is Rotten
    If NEITHER _#B_#B (or) KAPOW appears in Grocery Bag 1 or 2, then it is NO MATCH!

    Table
    Type (Juicy or Rotten or No Match) Grocery Bag 1 Grocery Bag 2
    should return JUICY BigApple_3B_3B BigApple
    should return JUICY BigApple_6B_6B BigApple
    should return JUICY BigOrange_7B_7B BigOrange
    should return ROTTEN BigApple KAPOW
    should return ROTTEN BigOrange KAPOW
    should return JUICY KAPOW Big Apple
    should return NO MATCH JBABY JBABY
    should return ROTTEN BigBanana BigBanana_5B_5B
    should return ROTTEN BigGrape BigGrape_10B_10B



    Thanks!!!
    Attached Files Attached Files
    Last edited by Cyson; 09-17-2014 at 01:44 AM.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Welcome to the forum.

    If your requirement is urgent, you should take the opportunity to read the forum rules about how to get your questions answered quickly.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    09-16-2014
    Location
    Boston, MA
    MS-Off Ver
    2013
    Posts
    10

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    I will read the forum rules, thanks !

  4. #4
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Try this in B10
    Please Login or Register  to view this content.
    and copy down.

    Is this what you are trying to achieve?
    Attached Files Attached Files
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  5. #5
    Registered User
    Join Date
    09-16-2014
    Location
    Boston, MA
    MS-Off Ver
    2013
    Posts
    10

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Hi Sktneer,

    Thank you so much for taking the time to address my problem.

    This works perfectly!

    As an additional improvement, if there are more criterias in the future, is there a better way to improve the formula so it won't just adding more scenarios in the same formula line.

    Is there a way to have the search function look at a 'List' where it contains all those words (with wildstrings/wildcards)

    Thanks!

  6. #6
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    You're welcome and thanks for the feedback. I depends on what are your additional criteria and how do you arrange a list of those words. Better if you upload another workbook with all the possible criteria with proper set up and let me see if I can provide you any further assistance.

  7. #7
    Registered User
    Join Date
    09-16-2014
    Location
    Boston, MA
    MS-Off Ver
    2013
    Posts
    10

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Hi sktneer,

    I have uploaded the excel file with the new conditions.

    Once again, thank you for your assistance!
    Attached Files Attached Files

  8. #8
    Forum Expert Vikas_Gautam's Avatar
    Join Date
    06-04-2013
    Location
    Ludhiana,Punjab, India
    MS-Off Ver
    Excel 2013
    Posts
    1,850

    Thumbs up Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Try this ...
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Check the attached file..
    Attached Files Attached Files
    Regards,
    Vikas Gautam
    Excel-buzz.blogspot.com

    Excel is not a matter of Experience, its a matter of Application.

    Say Thanks, Click * Add Reputation

  9. #9
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Other than the formula suggested by Vikas, you may also try this Array Formula. Remember Array Formula requires special keystrokes Ctrl+Shift+Enter instead of just Enter which you normally use in case of a regular formula. i.e. after typing the formula in the formula cell, don't press Enter alone but hold down Ctrl+Shift together and then press Enter to confirm the formula as an array formula. If an array formula is confirmed correctly, you will notice in the formula bar that the formula gets surrounded by the Curly Brackets {formula} and if you don't see the curly bracket that simple means the formula is not entered as an array formula. In that case select the cell with the formula, press F2 (Function Key) and then hold Ctrl+Shift together and then press Enter.

    In B23
    Please Login or Register  to view this content.
    and then copy down.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    09-16-2014
    Location
    Boston, MA
    MS-Off Ver
    2013
    Posts
    10

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    Both solutions work great! It's great to see two different ways of solving the same problem. You two are awesome!

  11. #11
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: URGENT: How to match a text cell with a list of texts and return a desired string of t

    You're welcome.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Search for a text string and return adjacent cell value for each match
    By ral8088 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 11-21-2013, 09:55 AM
  2. [SOLVED] Find partial text string within another text string return original text into cell.
    By mikey42979 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 06-17-2013, 02:58 PM
  3. Replies: 3
    Last Post: 06-17-2013, 01:09 PM
  4. Search text string for range of text values - return match
    By crugg in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-03-2010, 09:55 AM
  5. [SOLVED] Match row that contains text text string; list associated values from pivot table
    By ACurtis802 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-29-2009, 07:50 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1