LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Array takes 6x longer to process VLOOKUP than worksheet table does

I am running comparative performance tests and have an odd result. I can
post the code but the outcome is a bit surprising.

I read 10k rows which splits records resulting in 22k rows. In that process
I do a total of 100k VLOOKUPs (10k * 10 cells). When I built the 22k row
output directly to the worksheet, it took 12 seconds. I inserted an array,
built the output there and then moved the entire array to the worksheet at
the end of the procedure. That reduced processing time to 10 seconds (20%
reduction in elapsed time).

I then moved the "lookup table" to an array and the processing time jumped
to 60 seconds!

The questions a 1) does that make sense to you? and 2) do some functions
(like VLOOKUPs) become inefficient when used in arrays?

My guess is that I am doing something wrong like not setting the array as a
table (but I can't seem to figure out how to do that).

I can post the code but I don't want to tie up a lot of board space.... any
general ideas on this?


Thanks,
Ken
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Automatic Calculation in Code Takes Longer than Worksheet [email protected] Excel Programming 3 January 8th 09 06:18 PM
Code takes a long time to process Sandy Excel Programming 1 June 19th 08 08:08 PM
Rerunning Macro takes longer after each consecutive use....Why MikeZz Excel Programming 3 April 12th 07 02:07 PM
Double-clicking cell with =A1 no longer takes you to A1 in v2003? GoDario27 Excel Discussion (Misc queries) 6 August 16th 05 03:31 PM
How to use a cell value as Table Array in VLOOKUP worksheet function willydlish Excel Discussion (Misc queries) 2 February 16th 05 02:47 AM


All times are GMT +1. The time now is 04:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"