Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Get the total number of rows
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Divers
Thread ID:
00643239
Message ID:
00643252
Vues:
9
This message has been marked as a message which has helped to the initial question of the thread.
>Is there a way to get the total number of rows without doing a select *.
>
>I am do a import/export routine and want to make sure the table I am importing into does not have any existing data. Since I am walking down an array filled from SQLTABLE(gnConn), I don't know what the field names are to select just one field to count, and a count(*) would seem to be overkill.
>
>Thanks in advance
>
>Kirk

If your table is empty than SELECT COUNT(*) wouldn't take any time. The only difference's between SELECT COUNT(*) and SELECT COUNT(somefield) that the second dosn't count records with Nulls in Somefield.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform