Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why SELECT * faster than COUNT(*) in network?
Message
 
À
07/12/2000 06:24:39
Information générale
Forum:
Visual Basic
Catégorie:
Bases de données DAO/RDO/ODBC/ADO
Divers
Thread ID:
00450286
Message ID:
00450306
Vues:
34
>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

On which database engine?
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform