vlookup problem

Cossie

Active Member
Joined
May 6, 2002
Messages
328
I would like to return a value from a vlookup based on the value of A2.

In cell C3 I get the correct result, but i would like cell C4 to say browns plains and C5 to say woodridge. The formula is below. Any ideas anyone. Thanks a million. DC :biggrin:
Book4
ABCD
2logan
3LoganBeenleighBeenleigh
4LoganBrownsPlainsBeenleigh
5LoganWoodridgeBeenleigh
Sheet1
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
see this thread

"http://groups.google.com/group/microsoft.public.excel.worksheet.functions/
browse_frm/thread/c41750e2345c7639/ae16ddcb0ec7830f?lnk=st&q=vlookup+all+values+excel&rnum=8#ae16ddcb0ec7830f"
 
Upvote 0
I assume you must really have more data than this dummy set,
but why not simply put c3=if(a3=$A$2,b3,"") and copy down in column C.
 
Upvote 0
Book5
ABCD
1
2logan3
3LoganBeenleighBeenleigh
4LoganBrowns PlainsBrowns Plains
5LoganWoodridgeWoodridge
6 
Sheet1


C2:

=COUNTIF(A3:A5,A2)

C3:

=IF(ROWS($C$3:C3)<=$C$2,INDEX($B$3:$B$5,SMALL(IF($A$3:$A$5=$A$2,ROW($A$3:$A$5)-ROW($A$3)+1),ROWS($C$3:C3))),"")

which is confirmed with control+shift+enter (not just with enter) then coied down.
 
Upvote 0

Forum statistics

Threads
1,214,978
Messages
6,122,545
Members
449,089
Latest member
davidcom

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top