As is clear from the exchanges in this thread, you want to retrieve "joe" also when the lookup/key value is 3.
Note 1. It is better, if possible, not to associate the same key value with different values.
Assuming that A2:B5 houses your sample data:
In D1 enter: 3 [ a lookup/key value ]
In D2 enter:
=IF(COUNTIF(A:A,$D$1)>0,VLOOKUP($D$1,$A$2:$B$5,2,0),"Not Found")
In D3 enter:
=IF(COUNTIF(A:A,$D$1)>COUNTA($D$2:D2),VLOOKUP($D$1,$B$5:INDIRECT("A"&MATCH($D2,$B$1:$B$5,0)+1),2,0),"")
and copy down this till no more values are returned.
Note 2. If your data area is frequently changing (that is, the area is dynamic), a different approach might be more appropriate.
On 2002-03-09 17:06, Anonymous wrote:
Can I use vlookup with dublicate records?
ex.
ColumnA ColumnB
1 tom
2 steve
3 mike
3 joe
How can I vlookup 3 and return joe?
Any help would be great. I am new to excel.
Thank you