Listing, finding and describing stored procedures in mssql

Posted by

Note to self for future reference.

As I am re-importing all my (260) stored procedures into a new #EF6 model (long story why) – these are my favorite SQL statements today:

For listing out all the stored procedures in alphabetical order with their schema name:

SELECT [schema] = OBJECT_SCHEMA_NAME([object_id]), name FROM sys.procedures order by name;

Printing out the contents of a stored procedure (to read the return type):

EXEC sp_helptext N'[Golf80].[Tournaments].[SATLive_SetTeeTimes]’

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s