Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to get the total number of tables in a database?
Message
 
General information
Forum:
Microsoft SQL Server
Category:
Other
Miscellaneous
Thread ID:
01320465
Message ID:
01320466
Views:
12
Try
-- SQL 2005 and later
SELECT COUNT(*) FROM sys.tables

-- SQL 2000 and later
SELECT COUNT(*) FROM INFORMATION_SCHEMA.TABLES
	WHERE TABLE_TYPE = 'BASE TABLE'
>
>Is there SQL Syntax or Store Procedure to get the total number of tables in a database?
>
>
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform