+ Reply to Thread
Results 1 to 8 of 8

Search for a string and return specific value from multiple values in a column

  1. #1
    Forum Contributor
    Join Date
    02-21-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    100

    Search for a string and return specific value from multiple values in a column

    Dear Gurus, I have multiple duplicate entries in the First Column and I have Unique Values in the Third Column. I'm looking for searching for a particular string in the Second column with reference to the unique values in the Third Column and Return the number part in the required Forth Column.

    Attached the sheet with values.

    Please help

    Shiva
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2024
    Posts
    6,175

    Re: Search for a string and return specific value from multiple values in a column

    Try this in E2:

    =IFERROR(LOOKUP(2,1/($A$2:$A$36=D2)/(LEFT($B$2:$B$36,2)="RS"),--RIGHT($B$2:$B$36,LEN($B$2:$B$36)-4)),"")

  3. #3
    Forum Contributor
    Join Date
    02-21-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    100

    Re: Search for a string and return specific value from multiple values in a column

    That's fantastic my dear friend. Thanks a million. Added Repute.

    -Shiva

  4. #4
    Forum Contributor
    Join Date
    02-21-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    100

    Re: Search for a string and return specific value from multiple values in a column

    Hi Phuocam, this formula was working in my previous workbook, but doesn't seem to work (Not returning the RIGHT(),LEN()-4) as expected. I have attached the sheet.

    I have applied =IF(F2=0,IFERROR(LOOKUP(2,1/($A$2:$A$17=E2)/(LEFT($D$2:$D$17,2)="VN"),--RIGHT($D$2:$D$17,LEN($D$2:$D$7)-4)),""),"")

    in H2 Cell

    AND

    =IF(F2=1,IFERROR(LOOKUP(2,1/($A$2:$A$17=E2)/(LEFT($D$2:$D$17,2)="PI"),--RIGHT($D$2:$D$17,LEN($D$2:$D$7)-4)),""),"")

    in I2 Cell

    But not returning the values. Please help.

    Thanks in advance

    Shiva
    Attached Files Attached Files

  5. #5
    Forum Contributor
    Join Date
    02-21-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    100

    Re: Search for a string and return specific value from multiple values in a column

    Hi, could someone please help on this?

    Thanks in advance
    Shiva

  6. #6
    Forum Contributor
    Join Date
    02-21-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    100

    Re: Search for a string and return specific value from multiple values in a column

    Hi, I observed that the values "VN - PL3006" or "PI- IP5487" for example are alphanumeric is the reason why it is not returning the " LEN()-4 " values. When I'm putting a number for example "VN - 883006 and "PI - 125487" the formula is returning correctly.

    Could someone help to resolve this?

  7. #7
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2024
    Posts
    6,175

    Re: Search for a string and return specific value from multiple values in a column

    Change =IF(F2=0,IFERROR(LOOKUP(2,1/($A$2:$A$17=E2)/(LEFT($D$2:$D$17,2)="VN"),--RIGHT($D$2:$D$17,LEN($D$2:$D$7)-4)),""),"")

    to =IF(F2=0,IFERROR(LOOKUP(2,1/($A$2:$A$17=E2)/(LEFT($D$2:$D$17,2)="VN"),RIGHT($D$2:$D$17,LEN($D$2:$D$17)-4)),""),"")

  8. #8
    Forum Contributor
    Join Date
    02-21-2014
    Location
    Bangalore
    MS-Off Ver
    Excel 2007
    Posts
    100

    Re: Search for a string and return specific value from multiple values in a column

    Thanks ton buddy. It worked. Unable to add repute.

+ 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: 4
    Last Post: 10-01-2015, 11:01 AM
  2. [SOLVED] Search a string from a column, and return multiple values
    By newroads in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-11-2015, 03:43 PM
  3. Script to Search for a specific String then return cell values above that String-4
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-03-2015, 01:28 AM
  4. [SOLVED] Script to Search for a specific String then return cell values above that String-3
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-01-2015, 01:50 PM
  5. [SOLVED] Script to Search for a specific String then return cell values above that String-2
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-01-2015, 01:00 PM
  6. [SOLVED] Script to Search for a specific String then return cell values above that String
    By owensjb2 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-01-2015, 11:28 AM
  7. [SOLVED] Need to search for a specific string in Column A and delete values within the same row
    By hgeo24 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 02-27-2014, 04:56 PM

Tags for this Thread

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