Tag Archives: sp_msforeachtable

T-SQL – Find Number of Rows of Database(s) tables Using Undocumented Procedure – sp_MSforeachdb and sp_MSforeachtable

On Technet forum, Op was looking for a way to get table cardinality for all databases in an instance.  There are many ways to get the result. This post gives you an idea and SQL in which undocumented SP’s being called  “sp_MSforeachdb and … Continue reading

Posted in sp_MSforeachtable, SQL, T-SQL | Tagged , , , , , , , , , , | 1 Comment

SQL – List All Tables, Space Usage Info & Other Details

One of the OP requested in the forum to find all table details of any database. The details which includes Number of Rows,table size, index size etc:-. Even I frequently writing queries to list all such details. I’ve used SQLCMD mode to … Continue reading

Posted in Uncategorized | Tagged , , , , , | Leave a comment