Greetings Fellow Tek-Tippers!
I have a theoretical question to ask fo the group, hoping someone may know if I can speed up a function I have developed.
I have a two-phase macro set up, the first step generates a very large table (1.1M+ records), the second step analyses the first to generate a second table around the 1M record mark. Step #1 takes approximately 6 hours to process (I am okay with this timeline), but the second step has now been running for just over 4 days (96+ hours now) and is just now nearing completion.
In step two, I thought selecting the current account being processed and dumping the results to a temporary table (so the inner loop only has to look at the results for the current account) would be more effective, then emptying the temp table and repeating on each account to be processed would be the best approach. I am now wondering if the append and deletion steps are actually taking more processing time than if I just directly queried the first table (with all 1.1M records), just adding the current account being processed to the query selection criteria.
The Outer Loop in Step #2 will run aprroximately 22,000 iterations, with the Inner Loop on each running between 1 and 65 interations depending on the instance (averaging around 45).
I can provide the code if needed (process currently running), though wondering if anyone in the group has come across something similar and has any insight (as a 5-day turnaround time is not overly acceptable)?
I also have asked our IT staff about running this process on a virtual machine to see if that speeds up the processing time should there not be a more effective approach from the VBA-side.
Thanks in advance,
Mike
---------------------------------------------------------------
EvE Online: Claim the Destiny that is Rightfully Yours...
I have a theoretical question to ask fo the group, hoping someone may know if I can speed up a function I have developed.
I have a two-phase macro set up, the first step generates a very large table (1.1M+ records), the second step analyses the first to generate a second table around the 1M record mark. Step #1 takes approximately 6 hours to process (I am okay with this timeline), but the second step has now been running for just over 4 days (96+ hours now) and is just now nearing completion.
In step two, I thought selecting the current account being processed and dumping the results to a temporary table (so the inner loop only has to look at the results for the current account) would be more effective, then emptying the temp table and repeating on each account to be processed would be the best approach. I am now wondering if the append and deletion steps are actually taking more processing time than if I just directly queried the first table (with all 1.1M records), just adding the current account being processed to the query selection criteria.
The Outer Loop in Step #2 will run aprroximately 22,000 iterations, with the Inner Loop on each running between 1 and 65 interations depending on the instance (averaging around 45).
I can provide the code if needed (process currently running), though wondering if anyone in the group has come across something similar and has any insight (as a 5-day turnaround time is not overly acceptable)?
I also have asked our IT staff about running this process on a virtual machine to see if that speeds up the processing time should there not be a more effective approach from the VBA-side.
Thanks in advance,
Mike
---------------------------------------------------------------
EvE Online: Claim the Destiny that is Rightfully Yours...