RE: Difference between count(1) and count(*)

  • From: "Cary Millsap" <cary.millsap@xxxxxxxxxx>
  • To: <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 8 Jul 2004 10:16:32 -0500

I think "some reason" is that for decades people didn't know how to =
measure
performance (that is, response time). How can you possibly know what's =
GOING
to happen if you can't even tell what DID happen?!


Cary Millsap
Hotsos Enterprises, Ltd.
http://www.hotsos.com
* Nullius in verba *

Upcoming events:
- Performance Diagnosis 101: 7/20 Cleveland, 8/10 Boston, 9/14 San =
Francisco
- SQL Optimization 101: 7/26 Washington DC, 8/16 Minneapolis, 9/20 =
Hartford
- Hotsos Symposium 2005: March 6-10 Dallas
- Visit www.hotsos.com for schedule details...


-----Original Message-----
From: oracle-l-bounce@xxxxxxxxxxxxx =
[mailto:oracle-l-bounce@xxxxxxxxxxxxx]
On Behalf Of ryan.gaffuri@xxxxxxxxxxx
Sent: Thursday, July 08, 2004 8:38 AM
To: oracle-l@xxxxxxxxxxxxx; oracle-l@xxxxxxxxxxxxx
Cc: Tanel P=F5der
Subject: Re: Difference between count(1) and count(*)

for some reason there appears to be more B.S. associated with =
performance
tuning than any other Oracle topic. People are far more likely to pull =
stuff
out of their asses on performance tuning than anywhere else...=20

-------------- Original message --------------=20

> I've actually seen an "expert" optimizing the count() statement, by =
using=20
> count(null) "since null means nothing and thus is the fastest" :)=20
>=20
> But check this:=20
>=20
> SQL> select count(*) from dual;=20
>=20

----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
--
Archives are at //www.freelists.org/archives/oracle-l/
FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------

----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
--
Archives are at //www.freelists.org/archives/oracle-l/
FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------

Other related posts: