VLOOKUP only getting first line of data

electronictokwa

Board Regular
Joined
Oct 25, 2011
Messages
122
This is just a portion of where I am trying to do vlookup from another sheet. The lookup value is on the first column, and returned value is on the second column. Problem is, I am only getting the result for 1/1/2012, 1/2/2012 down are returning errors.

The VLOOKUP formula from the search tab:

=IFERROR(VLOOKUP(G4,DBList!B6:C370,2,0),"na")

I also used =WEEKNUM(B370,1) & " " & 2012 for the second column below to automatically count the workweek. Any ideas?


<table class="tableizer-table"> <tbody><tr class="tableizer-firstrow"><th>1/1/2012</th><th>1 2012</th><th>January 2012</th></tr> <tr><td>1/2/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/3/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/4/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/5/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/6/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/7/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/8/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/9/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/10/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/11/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/12/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/13/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/14/2012</td><td>2 2012</td><td>January 2012</td></tr></tbody></table>
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
This is just a portion of where I am trying to do vlookup from another sheet. The lookup value is on the first column, and returned value is on the second column. Problem is, I am only getting the result for 1/1/2012, 1/2/2012 down are returning errors.

The VLOOKUP formula from the search tab:

=IFERROR(VLOOKUP(G4,DBList!B6:C370,2,0),"na")

I also used =WEEKNUM(B370,1) & " " & 2012 for the second column below to automatically count the workweek. Any ideas?


<table class="tableizer-table"> <tbody><tr class="tableizer-firstrow"><th>1/1/2012</th><th>1 2012</th><th>January 2012</th></tr> <tr><td>1/2/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/3/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/4/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/5/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/6/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/7/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/8/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/9/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/10/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/11/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/12/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/13/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/14/2012</td><td>2 2012</td><td>January 2012</td></tr></tbody></table>


Which sort of error you are getting... can you elaborate it more?
 
Upvote 0
I included IFERROR on the VLOOKUP formula with "na" return value for errors, and that is what I am getting.

=IFERROR(VLOOKUP(G4,DBList!B6:C370,2,0),"na")
 
Upvote 0
This is just a portion of where I am trying to do vlookup from another sheet. The lookup value is on the first column, and returned value is on the second column. Problem is, I am only getting the result for 1/1/2012, 1/2/2012 down are returning errors.

The VLOOKUP formula from the search tab:

=IFERROR(VLOOKUP(G4,DBList!B6:C370,2,0),"na")

I also used =WEEKNUM(B370,1) & " " & 2012 for the second column below to automatically count the workweek. Any ideas?


<table class="tableizer-table"> <tbody><tr class="tableizer-firstrow"><th>1/1/2012</th><th>1 2012</th><th>January 2012</th></tr> <tr><td>1/2/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/3/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/4/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/5/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/6/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/7/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/8/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/9/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/10/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/11/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/12/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/13/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/14/2012</td><td>2 2012</td><td>January 2012</td></tr></tbody></table>


Try This...
=IFERROR(VLOOKUP(G4,DBList!$B$6:$C$370,2,0),"na")
 
Last edited:
Upvote 0
Thanks. But I am still getting the same error for 1/2/2012 down.

are you getting this error in all the cells now OR only for the above you mentioned? could you like to tell me please that which is the first cell where you putted that formula?
 
Upvote 0
Could you post a sample of your workbook?

VLOOKUP returns only the first item out of dups values if that's what your problem is.

George
 
Upvote 0
are you getting this error in all the cells now OR only for the above you mentioned? could you like to tell me please that which is the first cell where you putted that formula?

All cells except for the one with 1/1/2012 (cell B370). The formula to count the workweek =WEEKNUM(B370,1) & " " & 2012 is in cell C370. VLOOKUP is returning the value in this cell but not for the other cells; C371 down. Again, here are the tables:

This is the vlookup sheet:

<style type="text/css">
table.tableizer-table {border: 1px solid #CCC; font-family: Arial, Helvetica, sans-serif; font-size: 12px;} .tableizer-table td {padding: 4px; margin: 3px; border: 1px solid #ccc;}
.tableizer-table th {background-color: #104E8B; color: #FFF; font-weight: bold;}
</style><style type="text/css">
table.tableizer-table {border: 1px solid #CCC; font-family: Arial, Helvetica, sans-serif; font-size: 12px;} .tableizer-table td {padding: 4px; margin: 3px; border: 1px solid #ccc;}
.tableizer-table th {background-color: #104E8B; color: #FFF; font-weight: bold;}
</style>

<table class="tableizer-table">
<tr class="tableizer-firstrow"><th>Date Monitored</th><th>1/2/2012</th></tr> <tr><td>Work week</td><td>NA</td></tr> <tr><td>Evaluation Type</td><td></td></tr></table>



<table class="tableizer-table"> <tbody><tr class="tableizer-firstrow"><th>1/1/2012</th><th>1 2012</th><th>January 2012</th></tr> <tr><td>1/2/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/3/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/4/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/5/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/6/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/7/2012</td><td>1 2012</td><td>January 2012</td></tr> <tr><td>1/8/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/9/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/10/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/11/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/12/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/13/2012</td><td>2 2012</td><td>January 2012</td></tr> <tr><td>1/14/2012</td><td>2 2012</td><td>January 2012
</td></tr></tbody></table>
 
Upvote 0
Could you post a sample of your workbook?

VLOOKUP returns only the first item out of dups values if that's what your problem is.

George


But i did not see the duplicate values in given sample data...
 
Upvote 0
But i did not see the duplicate values in given sample data...

Yes you're right. But I am just wondering what the data is, what the outcome he wants to get and where is the table with the values....

So i made a guess if the data have dups vlookup will not do the job
 
Upvote 0

Forum statistics

Threads
1,214,875
Messages
6,122,044
Members
449,063
Latest member
ak94

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top