Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Why SELECT * faster than COUNT(*) in network?
Message
From
07/12/2000 06:24:39
 
 
To
All
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Title:
Why SELECT * faster than COUNT(*) in network?
Miscellaneous
Thread ID:
00450286
Message ID:
00450286
Views:
80
Hi,
Why SELECT * faster than COUNT(*) in network? I have a simple test as below:

FOR i =1 to 500
set rs = db.openrecordset('select * from mytabledbopensnapshot )
rs.close
NEXT i

it use 6 secs to finish.

However, if i use count(*)

FOR i =1 to 500
set rs = db.openrecordset('select count(*) from mytable',dbopensnapshot)
rs.close
NEXT i

it take 57 secs. why?

Thank you
I am not the most powerful man in this world.
I am not the worst man in this world either.
I just as same as all of you.
I still need to learn from my mistakes...
Next
Reply
Map
View

Click here to load this message in the networking platform