![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
By the way my latest testing indicates that a Sort will not use a date index unless there is a limitation on it. |
#3
| |||
| |||
|
|
Peter McMurray wrote: By the way my latest testing indicates that a Sort will not use a date index unless there is a limitation on it. You are right, D3 will select indexed dates if specified directly, but not relatively, e.g. select invoices with date ge 8-1-06 and le 1-8-06 (t will not use the index, but select invoices with date eq 8-1-06 8-2-06 8-3-06 8-4-06 8-5-06 8-6-06 8-7-06 8-8-06 (t will use the index. You can tell whether or not the index was used in the select by the message number returned: [4041] indicates the result is from the index, [401] indicates a non-index result. What I end up doing for files with date indexes is make a basic program that accepts a starting and ending date, then builds an explicit list of all the dates in between, then chains to a select like: select invoices with date eq "01-01-05" "01-02-05" "01-03-05" ... "12-31-05" It seems that the date range can be pretty large (10 years works, 11 doesn't?) before the tcl command line buffer overflows. BTW, Universe indexes do handle dates correctly, e.g. select invoices with date ge 1-1-06 and le 12-31-06 works quickly, as expected (but I don't know how to test to prove that the index was used, except for the obvious increase in speed). /Scott Ballinger Pareto Corporation Edmonds WA USA 206 713 6006 |
#4
| |||
| |||
|
|
Hi It seems that we have a long way to go to get indices fixed. I may be banging my head against a brick wall. Peter McMurray |
#5
| |||
| |||
|
|
BTW, Universe indexes do handle dates correctly, e.g. select invoices with date ge 1-1-06 and le 12-31-06 |
|
works quickly, as expected (but I don't know how to test to prove that the index was used, except for the obvious increase in speed). |
#6
| |||
| |||
|
|
Excalibur wrote: Hi It seems that we have a long way to go to get indices fixed. I may be banging my head against a brick wall. Peter McMurray Peter, You might want to check out 7.5 --> I seem to recall there being something in the Resolutions & Enhancements that talked about the use of indexed fields being "improved" in AQL. ... I'll check when I get back to the office. FWIW, 7.5 seems to be stable so far, and has certainly resolved so outstanding issues we were having at the site involved ... fingers crossed, and looking forward to play with the Linux BETA Not my place (has that ever stopped me?) but if anyone has a keen interest in D3/Linux platform, and wants a "heads up" on the new features, consider contacting RD & sign up for the beta if you have the resources .... and for any D3 users out there who HAVEN'T already downloaded the updated 7.5 documentation from the NT site, do yourself a favour & grab a copy. All sorts of "gems" that were previously hidden have been exposed - certainly a big step in the right direction I believe |
#7
| |||
| |||
|
|
Goo'day, Whale oil beef ........ !!!! On 9 Aug 2006 15:06:46 -0700, "Scott Ballinger" scott.ballinger (AT) gmail (DOT) com> wrote: BTW, Universe indexes do handle dates correctly, e.g. select invoices with date ge 1-1-06 and le 12-31-06 I was about to leap in, indignant to the core.... That COULDN'T work!! (No, not becasue of the back-arsewards date format..... <grin>) Thought I: T'would have to be ...with date ge "..." and DATE le "..." But, no. Tested on my last remaining UV old boiler and it works as stated.... Hi Bruce |
#8
| |||
| |||
|
|
Hi Ross All my remarks are directed at 7.5 although I have checked some of the results back against 7.4.4. |

#9
| |||
| |||
|
#10
| |||
| |||
|
|
"Peter McMurray" wrote: Hi Ross |
![]() |
| Thread Tools | |
| Display Modes | |
| |