vlookup malfunction?

B

Brian

in cell's c column i have a vlookup formula that looks at content of d (in
this case the content is a code number issued to every employee and it can be
as little as 5 digits to as many as 8 digits) then asks to find the code
number in the range G:I and return 2,false. G is the code number H is the
employees' ID#(which ranges from #243 up to right now its #427 but keeps
going up) and I is the employees' names. Some of the employee numbers do
not have a name associated with it and the name cell is blank.

THE PROBLEM: when i enter code numbers that do in fact exist, then I get
the corresponding employee number, HOWEVER, if there is a code number entered
that does not exist ( which would happen if someone is trying to take a guess
at another employees code number) then not all of the time but with certain
attempts at a bogus number, an employee name is returned even when their code
number is not even close to the one entered. And then after this name is
returned it will be returned for every bogus number a person can think of.
What is the reason for this, anyone know?

Thanks
Brian
 
F

Frank Kabel

Hi
you should have posted your formula. But I suspect you haven't defined
the 4th parameter.
If your formula looks like
=VLOOKUP(c1,A1:B100,2)

change it to
=VLOOKUP(c1,A1:B100,2,FALSE)
to look for an exact match
 
B

Brian

=IF(ISNA(VLOOKUP(D6,G:I,2,FALSE)),"",VLOOKUP(D6,G:I,2,FALSE))
this is what i am using.
 
F

Frank Kabel

Hi
could you email me an example file where you get a wrong return as your
formulas should workm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top