+ Reply to Thread
Results 1 to 3 of 3

Confused- Should I use Lookup, Match, Index?

Hybrid View

  1. #1
    Registered User
    Join Date
    11-12-2011
    Location
    america
    MS-Off Ver
    Excel 2003
    Posts
    19

    Confused- Should I use Lookup, Match, Index?

    Hello,

    I have a spreadsheet I'm using for schedules and I've hit a roadblock.

    Every day I need to create a list of employees scheduled, and historically this has been done by hand after referencing a file with the schedules. I want to automate the process, so by entering the date you'll return every employee scheduled that day in a list.

    I have a workbook with two sheets- sheet 1 is the list of employees, sheet two is the schedules.

    What I'm doing is using the unique employee numbers listed on both sheets combined with the date to create a new, unique number that can be searched for on sheet 2, then I need to return the results for the 2 columns immediately after that number to sheet 1 (start and end time).

    I was able to do this succesfully by making all of the data vertical, and using vlookup- but it isn't very user friendly for the person entering the schedules- so I was hoping there was a way to do it differently.

    TL;DR Version- How can I search for a number anywhere on sheet 2, and return the adjacent cell to sheet 1?


    Document attached for review.
    Attached Files Attached Files

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Confused- Should I use Lookup, Match, Index?

    How about in C5:

    =INDEX(Schedules!$D$4:$IT$33,MATCH($A5,Schedules!$A$4:$A$33,0),MATCH($B$3,Schedules!$D$2:$IT$2,0))

    copied down

    and in D5:

    =INDEX(Schedules!$D$4:$IT$33,MATCH($A5,Schedules!$A$4:$A$33,0),MATCH($B$3,Schedules!$D$2:$IT$2,0)+1)

    copied down
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    11-12-2011
    Location
    america
    MS-Off Ver
    Excel 2003
    Posts
    19

    Re: Confused- Should I use Lookup, Match, Index?

    That was exactly what I needed! Thank you so much, I spent way too many hours trying to figure this out on my own- and you solved it in 5 minutes.

    I'm truly grateful!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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