View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Mike H Mike H is offline
external usenet poster
 
Posts: 11,501
Default Comparing 1 number to 1000's and returning corresponding name

Hi,

assuming your range starts in Row1 put this in D1 and drag down

=INDEX($A$1:$A$3700,MATCH(E1,$B$1:$B$3700,FALSE),1 )

Mike

"EngelseBoer" wrote:

I have an excel file that now contains 37,000 + lines of entry on a dog breed
column A = name
column B = Reg. Nr
column C = M/F
Column D = (currently Blank) but represent the Sire
Column E = Sire's Reg Nr
Column F = (currently Blank) but represent the Dam
Column G = Dam's Reg. Nr

If say at row 100 -- dog XYZ has the sire with the Nr = 1234567 (in E)
I need column D - to compare that number in E100 with ALL those in B
and return the name(in D100) from A where the matching Nr is found in B

eg..

A B C D E

100 Sheila 3214 fem 1234567

120 Bob 6578 male
150 Toska 98765 fem
200 Millie 87654 fem

270 Duke 1234567 male

510 King 32768 male

766 Butch 8769 male


D100 must now return the name "Duke"

I don't know what command to use to do this with... or how ...

Thanks and regards
Malcolm