Forum Discussion

Deleted's avatar
Deleted
Mar 06, 2018

Vlookup not working properly

I'm a novice user, and this is my first post, so not sure i'm even doing this right. I feel I have my formulas right and Vlookup is not pulling the info. 

 

I have a schedule where depending on time, I can pull a different set of speakers and change the length of sessions. By changing the Program number in A4 from 1, 2 or 3, it should pull a different schedule from my DB. But I get #N/A when it should be returning values. Depending on what program I use, It shows more results. I'm not sure what I'm doing wrong. I have Excel 2010

 

I'm using (=VLOOKUP($A4,DB!$A$3:$I$16,2,FALSE)) as my formula

 

Attached is my file. Thanks for your help

 

Dan

  • Lloyd Adams's avatar
    Lloyd Adams
    Iron Contributor

    You need to ensure that column A on both sheets is text, and to be sure, reenter the values after having changed the column type.

    • Deleted's avatar
      Deleted

      Thanks Lloyd. But on my schedule, when I change A4 to a different number, I have a formula in A5-A8 to increase by .1. I can't have text in that column. Row 5 works, why wouldn't the rest? And just for kicks and giggles. I changed it all to text and I get no values showing. 

      • Lloyd Adams's avatar
        Lloyd Adams
        Iron Contributor

        Ok.  So I suspect you have a rounding error causing the issue.  Whilst keeping your data as numbers, change the vlookup to 

         

        =VLOOKUP(TRUNC($A7,2),DB!$A$3:$I$17,2,FALSE)

         

         

        Also check your ranges - not all your formulae include all your data - some stop at row 14.

Resources