Excel – How to manipulate the result of VLOOKUP function

microsoft excelworksheet-function

If VLOOKUP doesn't find a match, it returns something that looks like "#____".
However, I want to manipulate the VLOOKUP formula not to write anything in the cell if it doesn't find a match. (This picture is from Turkish Excel.)

How can I get VLOOKUP to return an empty result if it doesn't find anything?

alt text

Best Answer

You simply need to add an IF / ISNA command to the Vlookup function

=IF(ISNA(VLOOKUP(YOUR LOOKUP,FALSE)),"VALUE HERE",VLOOKUP(YOUR LOOKUP,FALSE))

You need to make sure that the last parameter or the Vlookup is set to false, and where I wrote Value Here, you need to keep the quotes, but simply have a blank space if you want it to be blank.

If your Vlookup command was : =VLOOKUP(B7,testsheet,2) and you wanted the value to be blank if it doesn't exist, you would use:

=IF(ISNA(VLOOKUP(B7,testsheet,2,FALSE)),"",VLOOKUP(B7,testsheet,2,FALSE))

Hope this helps you!

Related Question