View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default I need a clever VLOOKUP formula

since your data is sorted, why not use an approximate match Vlookup, it is
much faster. If the table is in A1:B3 and the value to look up is in D1,
then try:

=IF(VLOOKUP(D1,A1:B3,1,TRUE)=D1,VLOOKUP(D1,A1:B3,2 ,TRUE),"Not Found")

change ranges as needed.

"Henk57" wrote:


Hello:
I want to compare a dbase of 50000 or so with a new one of 8000
records. The purpose is to add the new ones only, so every record in
the newly establisehd dB remains clean with unique records. With a
simple VLOOKUP (using a fixed array with absoulte first and last cell
addresses) I get 50,000 x 8,000 calculations and I want to do this much
more intelligently. My idea is to sort both data bases alphabetically,
and to make the array defined in the VLOOKUP formula dynamically, i.e.
for instance only using the part that starts with the same first letter
of the record. Is this a sensible/possible approach? And if so, has
anyone an idea how to do that?




--
Henk57