Apr 03 2017
12:27 PM
- last edited on
Jul 25 2018
09:30 AM
by
TechCommunityAP
Apr 03 2017
12:27 PM
- last edited on
Jul 25 2018
09:30 AM
by
TechCommunityAP
I can get the VLOOKUP function to work fine if I enter it manually.
However, I have a sheet with over 700 rows and I want to use the fill handle to copy and auto-increment the VLOOKUP function to all the rows in each column.
As might be expected, the lookup value auto-increments row by row, which is good. However, the TABLE ARRAY ALSO AUTO-INCREMENTS! Therefore, by row 10 the function is only looking for a match in row 11 onward.
For example, here is the formula near the top of the data set:
=vlookup(J6,Sheet2!A1:D15,2,FALSE)
And here is the formula near the bottom of the data set:
=vlookup(J726,Sheet2!A721:D735,2,FALSE)
As you can see, the table array (the second parameter in the formula) has been auto-incrementing also, which means that the data in J726 will never find its match.
IS THERE A SOLUTION TO THIS PROBLEM, OTHER THAN MANUALLY TYPING IN THE INFORMATION FOR 700 ROWS AND 4 COLUMNS (2,800 TIMES)?
Thank you in advance.
Apr 03 2017 04:50 PM
To prevent a reference from changing you add a $ to the formula
=vlookup(J6,Sheet2!A$1:D$15,2,FALSE)
The $ infront of the numbers "locks" the rows
If you also want to lock the columns (so the formula doesn't change when you copy left / right) then put a $ infront of the letters also
=vlookup(J6,Sheet2!$A$1:$D$15,2,FALSE)