VLOOKUP acting weird

nmccracken12

New Member
Joined
Oct 8, 2020
Messages
37
Office Version
  1. 365
Platform
  1. Windows
I am sure this is an easy fix or easy answer. I created a VLOOKUP file a while back. It was intended to pull specific data from another workbook. This has worked almost flawlessly for years. Today, I am unable to pull any values for 5083 and up...

I have checked for spaces.
I checked the formatting and used format painter from working cells to paste to these cells.
I replaced 5083 with a smaller number (2032) that had been deleted off the sheet at some point. VLOOKUP functioned as expected. I changed the number back to 5083 and it's broken. The strange thing is it pulls a single column, but NOT what is actually in that column. Just a piece of it.

Any ideas?
 
Since you have MS365 you can try this. If it fixes your issue you have a data type mismatch:
Excel Formula:
=IFERROR(VLOOKUP(TRIM(W28),TRIM('[MadVines Master Pricing Database Encompass Implementation Full List.xlsx]Master List'!$1:$1048576),3,FALSE),"")
I tried that formula and got the same results. However, using that caused this error to start popping up, "Excel ran out of resources while attempting to calculate one or more formulas. As a result these formulas cannot be evaluated." Could this be related to the original issue?
 
Upvote 0

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.
This shows upload a mini sheet? Is there a way to just put the files on here? Attaching what you are asking for. Every column on the VLOOKUP is the same with a different index column number.
Here is a link to the two files. Let me know if it doesn't work. Excel
 
Upvote 0
No the resource issue is because you should never run a vlookup that is effectively reading the entire spreadsheet ie $1:$1048576. Specify a Range of cells (rows & columns) be generous but not 1 million + rows and not all columns
 
Upvote 0
No the resource issue is because you should never run a vlookup that is effectively reading the entire spreadsheet ie $1:$1048576. Specify a Range of cells (rows & columns) be generous but not 1 million + rows and not all columns
Gotcha and I can fix that easily.
 
Upvote 0
I believe you have spaces around the lookup value either in column W or column A in your database sheet. Try Alex's solution. If it works, there were spaces around your numbers
Not necessarily, I use Trim for number to text conversion because it handles a multitude of sins. By using it on both sides (lookup value and lookup array), it converts both sides to Text and as an added bonus cleans up spaces.
 
Upvote 0
I think your duplicate data in your master pricing database is probably what is causing your issue.
The vlookup is going to return the first one it finds which is in many cases blank.

Book2
ABCD
1QUOTE IDInternal IDNameCount
281124 Kilos Tierra De Mallorca2
341442018R. Stuart Vignette Pinot Noir2
44144Staglin Estate Chardonnay2
583315Terrassous Muscat Sec2
65081Alambique Serrano Barrel #2632
75082Alambique Serrano Navarre 72
850832
950842
1050852
1150862
1250872
1350882
145081Alambique Serrano Barrel #2632
155082Alambique Serrano Navarre 72
165083Cognac Hardy XO2
1750842508El Dorado High Ester LBI/DHE Rum2
1850852509El Dorado 18YO Bourbon & Cognac Finished Rum2
1950862510El Dorado 18YO Bourbon & Oloroso Sherry Rum2
2050872516El Dorado 12YR Rum 6pack AL2
2150882543El Dorado 25YR Rum 1btl AL2
Sheet1
 
Upvote 0
I think your duplicate data in your master pricing database is probably what is causing your issue.
The vlookup is going to return the first one it finds which is in many cases blank.

Book2
ABCD
1QUOTE IDInternal IDNameCount
281124 Kilos Tierra De Mallorca2
341442018R. Stuart Vignette Pinot Noir2
44144Staglin Estate Chardonnay2
583315Terrassous Muscat Sec2
65081Alambique Serrano Barrel #2632
75082Alambique Serrano Navarre 72
850832
950842
1050852
1150862
1250872
1350882
145081Alambique Serrano Barrel #2632
155082Alambique Serrano Navarre 72
165083Cognac Hardy XO2
1750842508El Dorado High Ester LBI/DHE Rum2
1850852509El Dorado 18YO Bourbon & Cognac Finished Rum2
1950862510El Dorado 18YO Bourbon & Oloroso Sherry Rum2
2050872516El Dorado 12YR Rum 6pack AL2
2150882543El Dorado 25YR Rum 1btl AL2
Sheet1
I called myself looking for duplicates, but I did figure it out finally. I highlighted column A and selected sort and filter and CLEAR. Excel was not showing any sort of filter being used in that column, but it opened a bunch of blank cells with ml/btl filled in and it was the exact numbers having issues. Thank you for your help!
 
Upvote 0
Thanks for letting us know. Glad we were able to help.
Reducing the data range used in your vlookup will be an added bonus and wouldn't have caused you performance issues at some point anyway.
 
Upvote 0

Forum statistics

Threads
1,223,230
Messages
6,170,883
Members
452,364
Latest member
springate

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