How to make Vlookup formula only a specific numbers in a range of data

questforexcel

Board Regular
Joined
Jan 18, 2019
Messages
128
Office Version
  1. 2013
Platform
  1. Windows
Hi,

Below are the numbers from which I want my vlookup formula to pick only the first 3 digits.

However, if there is a "0" in the beginning of the formula, I'd like it to only pick the next 2 digits after 0.

Could you please help me in this formula assessment.

Currently, I've used the formula =IFERROR(VLOOKUP(LEFT(A98,3),'USPS - Zone & Rate Chart'!$B$4:$I$125,2,1),"")

However, for the ranges starting with 0, it returns the blank value.

01022-1174
01057-9616
01104-2628



<colgroup><col></colgroup><tbody>
</tbody>
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
maybe
Code:
=IFERROR(VLOOKUP(--LEFT(A98,3),'USPS - Zone & Rate Chart'!$B$4:$I$125,2,1),"")
no real example - not tested
 
Last edited:
Upvote 0

Forum statistics

Threads
1,216,159
Messages
6,129,210
Members
449,493
Latest member
JablesFTW

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