+ Reply to Thread
Results 1 to 8 of 8

Search substring and return adjacent value

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    10-27-2005
    Posts
    177

    Search substring and return adjacent value

    *Sorry, I had to re-post again. This one is working now.

    Hello. I am hoping for some assistance with this problem I have.

    Please see attached. The desired actions are in the initial sheet and the desired results are in the Desired Result sheet.

    Any help would be much appreciated.
    Attached Files Attached Files
    Last edited by uberathlete; 08-02-2015 at 07:07 PM.

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Search substring and return adjacent value

    Try this...
    =VLOOKUP(LEFT(A2,10)&"*",$E$2:$F$7,2,0)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Forum Contributor
    Join Date
    10-27-2005
    Posts
    177

    Re: Search substring and return adjacent value

    Hi FDibbins. Thank you for the suggestion. Unfortunately, the formula will not work in all instances because the partial part numbers are not always 10 characters long.

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,355

    Re: Search substring and return adjacent value

    Hi uber,

    Try this in B2 and pull down.

    =VLOOKUP(LEFT(A2,FIND("G",A2)),$E$2:$F$7,2,FALSE)
    Attached Files Attached Files
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  5. #5
    Forum Expert Ace_XL's Avatar
    Join Date
    06-04-2012
    Location
    UAE
    MS-Off Ver
    2016
    Posts
    6,074

    Re: Search substring and return adjacent value

    Try in B2

    =LOOKUP(9.99E+307,SEARCH($E$2:$E$7,$A2),$F$2:$F$7)

    Copy down
    Life's a spreadsheet, Excel!
    Say thanks, Click *

  6. #6
    Forum Contributor
    Join Date
    10-27-2005
    Posts
    177

    Re: Search substring and return adjacent value

    Hi MarvinP and Ace_XL. I tried both formulas but it doesn't seem to work completely when I use a bigger data set, like the attached. For example, B2 should return Acer A501 Iconia Tab instead of unknown .
    Attached Files Attached Files

  7. #7
    Forum Expert Ace_XL's Avatar
    Join Date
    06-04-2012
    Location
    UAE
    MS-Off Ver
    2016
    Posts
    6,074

    Re: Search substring and return adjacent value

    My bad..Try

    =LOOKUP(2,SEARCH($E$2:$E$793,$A2),$F$2:$F$793)

  8. #8
    Forum Contributor
    Join Date
    10-27-2005
    Posts
    177

    Re: Search substring and return adjacent value

    Works like a charm. Thanks Ace_XL!

+ 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 value in row and return adjacent cell
    By lindseyd32833 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-11-2020, 04:03 PM
  2. Search for value, return value in adjacent cell
    By laerm in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 2
    Last Post: 08-13-2013, 01:12 PM
  3. Search for specific value in a row, then return content og adjacent cell
    By linaudio in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-20-2013, 09:11 AM
  4. Search substring within range, report the substring found
    By Brooke1578 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-20-2012, 03:56 PM
  5. Search string for substring...return match
    By Gambinus in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-21-2012, 03:18 PM
  6. Replies: 2
    Last Post: 06-29-2012, 07:02 AM
  7. Skakes in the Summer
    By lowryda777 in forum Excel General
    Replies: 2
    Last Post: 06-27-2012, 10:29 AM
  8. SEARCH MACRO FOR VALUE IN WORKBOOK, RETURN value of adjacent cell.
    By thequiff in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 06-15-2012, 10:47 AM

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