Subject | RE: [firebird-support] Re: 'select' with delays ref/eDN5012844953 |
---|---|
Author | Helen Borrie |
Post date | 2007-01-20T10:33:57Z |
At 08:04 PM 20/01/2007, you wrote:
Do you understand that, if you create an index, it is by default
ASCending? An ascending index cannot help to speed up a descending sort!
You can have both an ascending and a descending index on the same
column. The optimizer will choose the correct one for the sort if
you specify the sort as DESC.
./heLen
>Hello AdamDo you have a descending index on issue_date?
>After these backups and restores the database has the half size and it is
>much faster, 3-4 the initial query. The delay is restricted in the statement
>'order by issue_date desc'. This produces this delay, from user's interface
>I made this descent order optional, so if the user wants descent he will
>wait some seconds.
>
>Unfortunately didn't manage to reduce this delay.
Do you understand that, if you create an index, it is by default
ASCending? An ascending index cannot help to speed up a descending sort!
You can have both an ascending and a descending index on the same
column. The optimizer will choose the correct one for the sort if
you specify the sort as DESC.
./heLen