Monday, January 26, 2009

dbcc memusage

The "dbcc memusage" command is used for displaying the memory allocation for server structures and objects such as stored procedures.

The command will display the size and number of stored procedures as well as other server structures.

Usage:

dbcc traceon(3604)
go
dbcc memusage
go
dbcc traceoff(3604)
go

Don't forget the "dbcc traceon(3604)" sends trace output to the client (e.g. dbisql).

Note: The
"dbcc traceon(3604)"command can be applied to MS SQL Server as well.