Hello - I was wondering if anyone has experience or knows how to search an array using a binary search.
I currently have a piece of code that compares a main table (with 5000+ entries) to twenty other tables. It scans every line in each the other tables, finding its correlating value (if it exists in the main table) and updates a field in the main table array if the value is newer. However, as this search is currently done sequentially, by the time it is locating values in the second half of the table it is wasting time comparing at least 2500+ other values.
I have read plenty about binary searches on the web for other types of code including vb5 and above but cannot seem to use its functionality in vbscript.
Thanks for any help.
I currently have a piece of code that compares a main table (with 5000+ entries) to twenty other tables. It scans every line in each the other tables, finding its correlating value (if it exists in the main table) and updates a field in the main table array if the value is newer. However, as this search is currently done sequentially, by the time it is locating values in the second half of the table it is wasting time comparing at least 2500+ other values.
I have read plenty about binary searches on the web for other types of code including vb5 and above but cannot seem to use its functionality in vbscript.
Thanks for any help.