Sunday, March 7, 2010

Count number of tables in a SQL Server database

USE YOURDBNAME
SELECT COUNT(*) from information_schema.tables
WHERE table_type = 'base table'

in reference to:

"USE YOURDBNAMESELECT COUNT(*) from information_schema.tables WHERE table_type = 'base table'"
- Count number of tables in a SQL Server database | Sql Server Blog (view on Google Sidewiki)

No comments:

Post a Comment