Hello Mark
Thank you for your answer.
So, the clause ORDER BY should be used just when the table has few rows?
Because if do not use the indexes does not make sense to use it with big
tables.
Greetings.
Walter.
On Fri, Mar 1, 2013 at 8:41 AM, Mark Rotteveel wrote:
> **
>
>
> On Fri, 1 M
On Fri, 1 Mar 2013 08:32:09 -0400, W O
wrote:
> But the strange thing is that PER_IDENTI is the Primary Key and ORDER BY
> seems not use it.
As Firebird is retrieving all rows anyway, there is - AFAIK - no benefit
to use the primary key index for the ORDER BY. Unlike some other databases,
Firebir
Hello Mateusz
But PER_IDENTI is the Primary Key, why Firebird needs a two-pass proccess?
Greetings.
Walter.
On Fri, Mar 1, 2013 at 5:51 AM, Mateusz Loskot wrote:
> **
>
>
> On 1 March 2013 04:37, W O sistemas2000profesio...@gmail.com> wrote:
> > Somebody knows why there are a difference s
Hello Mark
Thank for your answer.
But the strange thing is that PER_IDENTI is the Primary Key and ORDER BY
seems not use it.
Greetings.
Walter.
On Fri, Mar 1, 2013 at 4:18 AM, Mark Rotteveel wrote:
> **
>
>
> On Fri, 1 Mar 2013 00:37:26 -0400, W O sistemas2000profesio...@gmail.com>
>
On 1 March 2013 04:37, W O wrote:
> Somebody knows why there are a difference so big?
>
> I have a table with 3.600.000 rows more or less.
>
> Writing:
> SELECT * FROM V_ABM_PERSONAS V WHERE V.PER_IDENTI > 0 ROWS 1 TO 100
>
> takes 2.656 seconds (less than 3 seconds)
>
> Writing:
> SELECT * FROM V
On Fri, 1 Mar 2013 00:37:26 -0400, W O
wrote:
> Somebody knows why there are a difference so big?
>
> I have a table with 3.600.000 rows more or less.
>
> Writing:
> SELECT * FROM V_ABM_PERSONAS V WHERE V.PER_IDENTI > 0 ROWS 1 TO 100
>
> takes 2.656 seconds (less than 3 seconds)
>
> Writing:
>
Somebody knows why there are a difference so big?
I have a table with 3.600.000 rows more or less.
Writing:
SELECT * FROM V_ABM_PERSONAS V WHERE V.PER_IDENTI > 0 ROWS 1 TO 100
takes 2.656 seconds (less than 3 seconds)
Writing:
SELECT * FROM V_ABM_PERSONAS V ORDER BY V.PER_IDENTI ROWS 1 TO 100