Lookup value with items in different rows

C

clubin

I am having trouble putting together a function that will lookup a given
value but return an associated value in a different row. i have tried
combinations of vlookup and offset to no avail.

To illustrate here is an example.

My table is set up as follows

A B
1 apple 10
2 20
3 30
4 pear 5
5 7
6 9

I would like to be able to lookup "apple" but instead of returning "10" I
need to return "20." Similarly, if I looked up "pear" i would need to return
"7" not "5."

Any help would be much appreciated.

Thank you in advance.
 
D

Dave Peterson

Check your other post.
I am having trouble putting together a function that will lookup a given
value but return an associated value in a different row. i have tried
combinations of vlookup and offset to no avail.

To illustrate here is an example.

My table is set up as follows

A B
1 apple 10
2 20
3 30
4 pear 5
5 7
6 9

I would like to be able to lookup "apple" but instead of returning "10" I
need to return "20." Similarly, if I looked up "pear" i would need to return
"7" not "5."

Any help would be much appreciated.

Thank you in advance.
 
M

Mike H

I think I prefer the rudeness of not responding at all to multi posting.
Please don't do it.
 
D

Dave Peterson

But if you notice that the multipost, you may want to warn others--especially if
there are responses at the other post(s).
 

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