Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Performance with ORDER BY !!!
I know that you can add an index on the ORDER BY field. Then, with the
hint /* +FIRST_ROWS */ you can force that the rows will be returned in
already sorted order. This does not always solve the problem. Let's
see the following example:
SELECT .. FROM .. WHERE Field1=x ORDER BY Field2 Index on The field used in Clause1 and index on Field1
Can I get ORACLE to apply the one or other approach depending on the case? I experienced that FIRST_ROWS FORCES the index scan independently of the sharpness of the where clauses. Received on Mon Dec 06 1999 - 04:24:48 CST
![]() |
![]() |