+ Reply to Thread
Results 1 to 9 of 9

Vlookup Help

  1. #1
    Forum Contributor
    Join Date
    10-13-2015
    Location
    Culloden, West Virginia
    MS-Off Ver
    2010
    Posts
    168

    Vlookup Help

    I'm using vlookup to populate a column using this formula: =IF(VLOOKUP(AA11,List!D2:D27,1,FALSE),"Pay Day","")

    It works, when it sees AA11 (which is a date) matches an entry from the "List" worksheet, it populates that cell with "Pay Day".

    The problem I have is when there isn't anything there it returns "#N/A". I attempted to remedy that with the IF statement-value if false "". No luck.

    I have attached the file for reference.
    Attached Files Attached Files

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,872

    Re: Vlookup Help

    Use the iferror function instead.

    https://exceljet.net/excel-functions...error-function
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Contributor
    Join Date
    10-13-2015
    Location
    Culloden, West Virginia
    MS-Off Ver
    2010
    Posts
    168

    Re: Vlookup Help

    I'm doing something terribly wrong.

    =IF(VLOOKUP(AA11,List!$D$2:$D$27,0),"Pay Day",IFERROR(VLOOKUP(AA11,List!$D$2:$D$27,0),""))

    I'm trying to use the iferror as my "value if false" formula.

    How do I use the IFERROR formula and still return my "value if true"?

  4. #4
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Vlookup Help

    As per your data, you have list.
    Your pay day schedule every 14 days.
    But not mention other list. What is criteria.
    Secondly, for pay day : After 14 days, If it is coming "sunday" which is Holiday, then become problem. instead of that kindly set pay day on "Monday".
    I have work out in your file, refer attach, Hope it is helpful for you.
    Instead of vlookup use index match
    In "V11"
    PHP Code: 
    =IFERROR(INDEX(List!$G$2:$G$366,MATCH('2018'!$C11,List!$E$2:$E$366,0)),""
    Attached Files Attached Files


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  5. #5
    Forum Contributor
    Join Date
    10-13-2015
    Location
    Culloden, West Virginia
    MS-Off Ver
    2010
    Posts
    168

    Re: Vlookup Help

    To simplify I made an additional simple version.

    In column A I have the date. In columns E and F I have made two lists, One for Holidays for the year and one for the Pay Days of the year. I manually populate those lists.

    If a date appears in one of the two lists, I want that List header to populate in column B next to the date.

    Example: Cell A2 is New Years day, 1/1/2018, so it is in the holiday list. I want Cell B2 to display "Holiday"

    Example: Cell A13 , 1/12/18, is a pay day, so it is in the pay day list. I want cell B13 to display "Pay Day"

    There is likely going to be an issue if I have the same date in both lists, but I'll cross that bridge (if) I get to it.
    Attached Files Attached Files

  6. #6
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Vlookup Help

    In fact, you can remove the helper column Z:AA, and using this in V11:

    Please Login or Register  to view this content.
    Also, You are having Pay Days list in sheet "List"by adding every 14 days to first Pay Day 01/01/2018. You can remove it and using this formula in V11:

    Please Login or Register  to view this content.
    P/S: Have not noticed you update info. Will come back later.
    Last edited by bebo021999; 05-11-2018 at 02:59 AM.
    Quang PT

  7. #7
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Vlookup Help

    In B2:

    Please Login or Register  to view this content.
    Drag down

  8. #8
    Forum Contributor
    Join Date
    10-13-2015
    Location
    Culloden, West Virginia
    MS-Off Ver
    2010
    Posts
    168

    Re: Vlookup Help

    That worked exactly how I was wanting. Thank you very much.

  9. #9
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Vlookup Help

    Sharing my experience, if Pay day falls into Holiday, actually Pay day will be next day.
    For instant, Pay day is on 1/1/2018, it is Holiday also, so Pay day will be 1/2/2018 (next day)

    Try this formula in general:

    Please Login or Register  to view this content.

+ 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: 5
    Last Post: 12-07-2016, 09:18 AM
  2. [SOLVED] When vlookup ragnes is mutiple: How do vlookup value finding occurrence against coresspond
    By silambarasan.J in forum Excel Formulas & Functions
    Replies: 34
    Last Post: 07-07-2015, 09:32 AM
  3. Replies: 0
    Last Post: 12-26-2013, 01:12 PM
  4. Display Cell within VLookup range that excel thinks matches the VLookup Value
    By headachexcelperson in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-04-2013, 04:56 PM
  5. how to bring all vlookup returns even with duplicate vlookup search keys
    By NYC4LIFE in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-06-2013, 04:53 PM
  6. vlookup? match? index? MULTIPLE criteria for vlookup search problem....
    By aborg88 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 02-11-2013, 09:56 AM
  7. Replies: 5
    Last Post: 07-29-2009, 07:53 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