Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Finding total Rows without count() ?
Kurt Harless <kharless_at_styl.com> wrote in message news:838cqr$h9k$1_at_nnrp03.primenet.com...
> Note...
>
> Instead of doing a count(*) use count('x'), or any literal, this prevents
> the parser from having to determine the columns for the query. This speeds
> up count a bit.
>
> Kurt
No!
It's one of the most prevalent misconceptions.
Using count(*) just needs to count the row headers,
but using count('x') must count the row header, then performs 'x' for each row.
So, count(*) takes less CPU, less memory usage, less time than count('x') or count(1) or count(rowid). Received on Thu Dec 16 1999 - 09:28:15 CST
![]() |
![]() |