SQL server tutorials
Showing posts with label
Table
.
Show all posts
Showing posts with label
Table
.
Show all posts
Thursday, 22 August 2013
Finding total Size/Space of the Table in sql server
sp_spaceused
'MyTable' Returns information about the size of MyTable
Syntax:
Exec sp_spaceused 'TableName'
Query:
Exec sp_spaceused 'MyOrdersPrimary'
Finding Size of ALL TABLES in the Current Database
List the space used in all tables within the currently connected database.
It takes all the tables from the currently connected database and displays the size of the table in the result window.
exec
sp_msforeachtable
"sp_spaceused '?'"
Older Posts
Home
Subscribe to:
Posts (Atom)