vlookup to return 2 columns

G

Guest

hi

can use vlookup function to return with 2 columns value ?

example:

A B C
1 H Home $200

2 C Car $100

3 B Boat $250


by using the above range, i know how to use the vlookup to return, say, A1,
it return for me "Home"...(i.e: =vlookup(lookupValue,A1:C3,2)

how can i use the lookup to return more than 1 data, example, base on the
above, I want it to display for me "Home" and "$200", and have them place in
separated cell?

any help community ?

thanks community :)
 
T

T. Valko

You need 2 formulas in 2 cells.

Actually, you can enter 1 formula in 1 cell and then just drag copy across
to the other cell.

Try this:

=VLOOKUP(lookup_value,$A$1:$C$3,COLUMNS($A:B),0)

Now just drag copy across to the other cell.

If the lookup_value is a reference to a cell make at least the column
reference absolute:

H1 = lookup_value

=VLOOKUP($H1,$A$1:$C$3,COLUMNS($A:B),0)

Biff
 
G

Guest

hi T. Valko :) thanks it works well :)
the 2nd formula works fine, need to absolute the lookup range

much appreciated :)

thanks again

thanks community
 
L

L. Howard Kittle

Another way...

Select two cells in a row and while selected type in this lookup formula:

=VLOOKUP(D1,A1:C3,{2,3},0)

Now hit Ctrl + Shift + Enter, you will get { }'s around the formula and
your lookup values will be in the two cells.

HTH
Regards,
Howard
 
T

T. Valko

You're welcome. Thanks for the feedback!

Biff

oldLearner57 said:
hi T. Valko :) thanks it works well :)
the 2nd formula works fine, need to absolute the lookup range

much appreciated :)

thanks again

thanks community
 
G

Guest

thanks L. Howard Kittle :) much appreciated :)
yes! it works good

thanks again

thanks community
 

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