Re: Another Excel problem
For e column (start at E2 and drag down)
=VLOOKUP(D2,$A$2:$C$7046,2,0)
For column F (start at E2 and drag down)
=VLOOKUP(D2,$A$2:$C$7046,3,0)
Vlookup({What to search for}, {where to search 1st column of a grid}, {which column to return from grid}, {Exact Match (False)}
So for cell E2 we are looking up D2 in the grid A2:C7036 (the $$ are to fix the grid from changing when dragging) and we want to return 2nod column and what an exact match.
This will return only the first match so it is better if column A is unique.
Re: Another Excel problem
Also if you add rows to the A-C columns you will have to extend the grid in the formula so might be wise to preempt that by changing to
=VLOOKUP(D2,$A$2:$C$20000,2,0)
or you can do =VLOOKUP(D2,A:C,2,0) I just being old skool think that looking up over a million rows just because being lazy each time is a bit too drastic.
As further down the line this will start going funky and no one will work it out ;-)
Re: Another Excel problem