+ Reply to Thread
Results 1 to 7 of 7

INDEX, MATCH and RIGHT

  1. #1
    Registered User
    Join Date
    12-07-2018
    Location
    London
    MS-Off Ver
    2016
    Posts
    9

    INDEX, MATCH and RIGHT

    Hey,

    I am trying to match two values on the last 14 digits of the string.

    Example:

    Match:
    8993017100193540280F
    w/
    89930107100193540280F

    I can do it if I create a separate column with a separate RIGHT formula on each tab and then index but I would like to try and get it into one formula.

    I thought if I just added the right into the formula it would work:
    =INDEX(Index!A1:A5,MATCH(RIGHT(A1,14),Index!B1:B5,0))

    but it seems I need to get the index to right as well.

    Attached an example.

    Any help greatly appreciated!
    Attached Files Attached Files

  2. #2
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,077

    Re: INDEX, MATCH and RIGHT

    How about
    =INDEX(Index!A1:A5,MATCH(RIGHT(A1,14),RIGHT(Index!B1:B10,14),0))

    Might need Ctrl Shift Enter, rather than just enter.

  3. #3
    Valued Forum Contributor
    Join Date
    02-04-2009
    Location
    Texas
    MS-Off Ver
    Excel 2016
    Posts
    665

    Re: INDEX, MATCH and RIGHT

    it is the Index - needs to be 1

    =Index(Index!$A$1:$A$5,Match(Right($A1,14),Index!$B$1:$B$5,0),1)

    Also you probably want to use fixed ranges ($) because when you copy down you don't want the Index and Match ranges to move

  4. #4
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: INDEX, MATCH and RIGHT

    Please try

    =INDEX(Index!A:A,MATCH("*"&RIGHT(A1,14),Index!B:B,0))

  5. #5
    Valued Forum Contributor
    Join Date
    02-04-2009
    Location
    Texas
    MS-Off Ver
    Excel 2016
    Posts
    665

    Re: INDEX, MATCH and RIGHT

    Sorry - should have looked at the workbook... I cede to Fluff's idea

    =INDEX(Index!A:A,MATCH(RIGHT(A1,14),RIGHT(Index!B:B,14),0))

  6. #6
    Registered User
    Join Date
    12-07-2018
    Location
    London
    MS-Off Ver
    2016
    Posts
    9

    Re: INDEX, MATCH and RIGHT

    Fluff worked perfectly thank you!!

  7. #7
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,077

    Re: INDEX, MATCH and RIGHT

    You're welcome & thanks for the feedback.

+ 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. [SOLVED] INDEX+MATCH instead of VLOOKUP+MATCH, why is INDEX a better choice and how to re-write?
    By Renejorgensen in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-23-2016, 10:54 AM
  2. [SOLVED] Index / Match - match 3 input values and return the results from the index
    By t83357 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-08-2016, 07:34 PM
  3. [SOLVED] Match-Index in stead of Index-Match lookup Array among Arrays
    By Numnum in forum Excel General
    Replies: 2
    Last Post: 10-15-2015, 02:08 PM
  4. INDEX MATCH MATCH/OFFSET MATCH MATCH with named ranges
    By Andrew-Mark in forum Excel General
    Replies: 3
    Last Post: 02-27-2015, 10:56 PM
  5. Replies: 6
    Last Post: 04-30-2014, 02:42 AM
  6. Replies: 6
    Last Post: 11-08-2013, 10:29 PM
  7. Replies: 3
    Last Post: 05-02-2013, 01:31 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