Vlookup Function

C

Christopher Naveen

Hi,

Pls refer the vlookup formula mentioned below,

Cell : A2,
=VLOOKUP(A1,'[Jan''08.xls]Sheet1'!$B:$D,3,0)

I am entering the vlookup function in cell A2 and here i want to do multiple
functions. Ex : 1st this formula will execute and return a value and if it
returns #n/a it shud automatically look for the different table with
different vlookup function.

I tried with if condition and it returns a circular reference error.

Is it possible to execute the multiple function? If yes i request any one of
ur help.

Thanks in advance!

-Christ.
 
M

Max

One way is to nest it, indicatively like this:
=IF(ISNA(VLOOK1),IF(ISNA(VLOOK2),"",VLOOK2),VLOOK1)
The sequence structured is important if the lookup value could be found in
multiple lookup tables. If there's no possibility of this happening, then it
doesn't matter.
 
C

Christopher Naveen

Hi,

Thanks for ur immediate response and it is working fine. Also i have 1 more
query. 1st vlookup will look for #n/a and if it is true it will check for 2nd
vlookup but here inbetween i want to check 1 more condition.

After the execution of the 1st Vlookup if the result is "India" then reject
this result and go for 2nd vlookup. I have few countries in the lookup master
table and i need to reject particularly "india" and lookup for the 2nd
vlookup. I hope u understood my query. Can u pls help me on this.

Looking forward for ur response. Thanks a bunch.

-Christ

Max said:
One way is to nest it, indicatively like this:
=IF(ISNA(VLOOK1),IF(ISNA(VLOOK2),"",VLOOK2),VLOOK1)
The sequence structured is important if the lookup value could be found in
multiple lookup tables. If there's no possibility of this happening, then it
doesn't matter.

Christopher Naveen said:
Hi,

Pls refer the vlookup formula mentioned below,

Cell : A2,
=VLOOKUP(A1,'[Jan''08.xls]Sheet1'!$B:$D,3,0)

I am entering the vlookup function in cell A2 and here i want to do
multiple
functions. Ex : 1st this formula will execute and return a value and if it
returns #n/a it shud automatically look for the different table with
different vlookup function.

I tried with if condition and it returns a circular reference error.

Is it possible to execute the multiple function? If yes i request any one
of
ur help.

Thanks in advance!

-Christ.
 
M

Max

Indicatively, think you could try something like this (all in 1 cell):
=
IF(OR(ISNA(VLOOK1),VLOOK1="India"),
IF(OR(ISNA(VLOOK2),VLOOK2="India"),"",
VLOOK2),VLOOK1)
 

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