+ Reply to Thread
Results 1 to 4 of 4

SEARCH 3 columns and return column label

  1. #1
    Registered User
    Join Date
    09-07-2011
    Location
    Brighton, England
    MS-Off Ver
    Excel 2007
    Posts
    23

    SEARCH 3 columns and return column label

    I am exporting data from a database. There are 3 columns which contain True or False depending on a database tag. The columns are labeled High, Medium and Low.

    the following works well but only finds data in 1 column:

    =IF(ISERROR(SEARCH("True",AO2)),"","High")
    =IF(ISERROR(SEARCH("True",AP2)),"","Medium")
    =IF(ISERROR(SEARCH("True",AQ2)),"","Low")

    I know I can do this for each column as above and merge the results but it would be great to do this in one statement if possible.

    I hope someone can help.

    Thanks

    Simon

  2. #2
    Forum Expert Debraj Roy's Avatar
    Join Date
    09-27-2012
    Location
    New Delhi,India
    MS-Off Ver
    Excel 2013
    Posts
    1,469

    Re: SEARCH 3 columns and return column label

    @ Admin / Mod
    Please close.. Duplicate..

    http://www.excelforum.com/excel-form...umn-label.html
    Regards!
    =DEC2HEX(3563)

    If you like someone's answer, click the star to give them a reputation point for that answer...

  3. #3
    Forum Expert Debraj Roy's Avatar
    Join Date
    09-27-2012
    Location
    New Delhi,India
    MS-Off Ver
    Excel 2013
    Posts
    1,469

    Re: SEARCH 3 columns and return column label

    @ Admin / Mod
    Please close.. Duplicate..

    http://www.excelforum.com/excel-form...umn-label.html

  4. #4
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: SEARCH 3 columns and return column label

    try
    =iferror(CHOOSE(MATCH(TRUE,AO2:AQ2,0),"high","medium","low")"") if true is realy text then use
    =iferror(CHOOSE(MATCH("TRUE",AO2:AQ2,0),"high","medium","low")"")
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

+ 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. Replies: 13
    Last Post: 07-03-2013, 07:03 AM
  2. Search for value in multiple columns, Return Column Headers
    By Zach51215 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-30-2013, 06:49 AM
  3. [SOLVED] VLOOKUP to search multiple columns and return value from single column
    By BBExcelusr in forum Excel - New Users/Basics
    Replies: 9
    Last Post: 08-01-2012, 01:12 PM
  4. Search in Mulitple Columns and Return Corresponding Column/Row Result
    By JLRO in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 05-05-2008, 10:42 AM
  5. [SOLVED] Search Multiple columns for criterion asterisk (*) and Return Numeric Label
    By Sam via OfficeKB.com in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 07-14-2006, 02:00 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