Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
MSSQL Count of Records
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00838665
Message ID:
00838677
Views:
24
Thanks! I sent the info on to my friend!

>Works great on a 46 million row table I've got.
>
>>Thanks for the info!
>>
>>>>A friend of mine, here is trying to get a count of how many records are in a SQL table in MS-SQL.
>>>>
>>>>He tried SELECT COUNT(*) AS TOTRECS FROM MASTER_EVENT
>>>>
>>>>And it takes FOREVER to get a count because the record has around 12 Million Records.
>>>>
>>>>How to speed this up?????
>>>>
>>>>Thanks!!!!
>>>>
>>>>Tommy
>>>
>>>If you've never had any records deleted, you could use something like this if you have an identity field:
>>>
>>>SELECT TOP 1 LogID AS TotalRecs FROM tblLog ORDER BY LogID DESC
Tommy Tillman A+ NetWork+ MCP
Previous
Reply
Map
View

Click here to load this message in the networking platform