Vlookup return 0 instead of N/A

Posted on 2012-09-15
Medium Priority
Last Modified: 2012-09-15
When I copy my vlookup formula down I get either a number or N/A. Instead of the N/A I want a formula that would return a 0. My vlookup formula is below.


I found this formula below on a website...and I tried to modify it for my use but it did not work.

=IF(COUNTIF($B$2:$B$100,A1), VLOOKUP(A1,$B$2:$D$100,3,0),””) (this is not my modified version)

Any help would be appreciated.

Question by:Edward Pamias
LVL 25

Accepted Solution

lwadwell earned 2000 total points
ID: 38401713
use the isna function, e.g.
LVL 70

Expert Comment

ID: 38401725
the formula below returns 0 if A3 is blank - is this what you want?

LVL 26

Expert Comment

ID: 38401732
Hi, epamias.


This has...
... the advantage that the data is searched only once. (Trivial in this case, but often significant)
... the disadvantage that IFERROR didn't exist before Excel 2007.

LVL 19

Author Closing Comment

by:Edward Pamias
ID: 38401735
Thank you! This one worked. The last formula worked as well. Sorry I did not see that until after I accepted the ISNA formula.
LVL 26

Expert Comment

ID: 38401810
Not a problem, epamias. Glad you're sorted.

Featured Post

Granular recovery for Microsoft Exchange

With Veeam Explorer for Microsoft Exchange you can choose the Exchange Servers and restore points you’re interested in, and Veeam Explorer will present the contents of those mailbox stores for browsing, searching and exporting.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post, I will showcase the steps for how to create groups in Office 365. Office 365 groups allow for ease of flexibility and collaboration between staff members.
This holiday season, we’re giving away the gift of knowledge—tech knowledge, that is. Keep reading to see what hacks, tips, and trends we have wrapped and waiting for you under the tree.
This Micro Tutorial will demonstrate the scrolling table in Microsoft Excel using the INDEX function.
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question