+ Reply to Thread
Results 1 to 3 of 3

This formula works but I donīt understand why Index(Index) match

  1. #1
    Registered User
    Join Date
    06-22-2015
    Location
    lisbon
    MS-Off Ver
    windows 8
    Posts
    33

    This formula works but I donīt understand why Index(Index) match

    Hi,

    Let's say I have a column (A1:A10) where I have several animals, and I want to find the position of the second "Cat" which I write in cell B1.

    Col A
    Cat
    Dog
    Bear
    Cat
    Turtle

    I can use this formula (it works) =MATCH(B1,INDEX(INDEX(A1:A10,MATCH(B1,A1:A10,0)+1):A10,0),0)+MATCH(B1,A1:A10,0), my issue is with the bold part. (INDEX(A1:A10,MATCH(B1,A1:A10,0)+1), this will give you "Dog" than you have an Index ("dog":A10,0)..... how can this work? I get the general idea that relative to dog the 2nd Cat is in the position 3, and then you sum the first to get the position from the beginning.

    Thanks
    Last edited by campelliann; 01-25-2016 at 05:17 PM.

  2. #2
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Re: This formula works but I donīt understand why Index(Index) match

    Regarding this formula:
    Please Login or Register  to view this content.
    1) When you resolve the inner INDEX section, Excel shows you the contents of the cell. But, internally, the INDEX function returns a reference. In your case, it's a reference to cell A2.
    2) Because you're constructing an array for the outside MATCH function to reference, you'd need to either CTRL+SHIFT+ENTER the formula or wrap the array in an INDEX function (eliminating the need to C+S+E).

    Side note: Either of these two functions will return the row reference you want
    This ARRAY FORMULA, completed by holding down CTRL and SHIFT when you press ENTER (instead of just pressing ENTER)
    Please Login or Register  to view this content.
    or this regular formula
    Please Login or Register  to view this content.
    Does that help?
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  3. #3
    Registered User
    Join Date
    06-22-2015
    Location
    lisbon
    MS-Off Ver
    windows 8
    Posts
    33

    Re: This formula works but I donīt understand why Index(Index) match

    Thank you a lot! your explanation was great, repped!

+ 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: 1
    Last Post: 05-08-2014, 10:21 AM
  2. Replies: 6
    Last Post: 04-30-2014, 02:42 AM
  3. Replies: 3
    Last Post: 05-02-2013, 01:31 AM
  4. [SOLVED] Struggling to understand the Index/Match functions
    By PosiJoel in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-26-2012, 08:57 PM
  5. [SOLVED] Understand lookup, index & match formulae
    By Dushantha in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-18-2012, 05:50 AM
  6. [SOLVED] I cant understand this formula (index+match+counif)
    By Alexander_Golinsky in forum Excel General
    Replies: 3
    Last Post: 05-08-2012, 08:04 AM
  7. Index Match question........dont understand this result
    By welchs101 in forum Excel General
    Replies: 3
    Last Post: 11-17-2011, 10:52 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