Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: URGENT NEED OF HELP ABOUT PL/SQL
On Tue, 02 Sep 1997 21:43:49 GMT, martinj_at_worldonline.nl (Martin Jesterhoudt) wrote:
>
>On 31 Aug 1997 12:57:52 GMT, jstrange_at_imtn.dsccc.com (John Strange)
>wrote:
>
>>Also, use
>> select count (rowid)
>>it will run faster.
>
>Use select count(<indexed_column>) if possible. This way you don't
>have to go through the table, but only the index. Even faster ;-))
>
>-------------------------------------------------------------------------------
>--- Martin Jesterhoudt ---
>--- martinj(replace this by @)worldonline.nl ---
>-------------------------------------------------------------------------------
I thought Oracle was smart enough to optimize "count(*)" to use whatever the fastest method should be. I don't believe there is any performance penalty for coding it this way.
Dave Received on Wed Sep 03 1997 - 00:00:00 CDT
![]() |
![]() |