How can I get all the system stored procedures listed by MS SQL Server (2012) using an SQL query?
In order to fetch the multiple returned values from the Stored Procedure, you need to make use of a variable with data type and size same as the Output parameter and pass it as Output parameter using OUTPUT keyword. You can also make use of the Split function to split the comma separated (delimited) values into rows.
Using SQL Server Management StudioIn Object Explorer, connect to an instance of Database Engine and then expand that instance. Expand Databases, expand the database in which the procedure belongs, and then expand Programmability. Expand Stored Procedures, right-click the procedure and then click View Dependencies.
sysobjects is deprecated. You can use
SELECT QUOTENAME(SCHEMA_NAME(schema_id)) + '.' + QUOTENAME(name)
FROM   sys.all_objects
WHERE  type = 'P'
       AND is_ms_shipped = 1 
                        SELECT sch.name + '.' + obj.name
  FROM sysobjects obj, sys.schemas sch
  WHERE obj.type = 'P'
    AND sch.schema_id = obj.uid
    AND sch.name = 'sys'
    --AND obj.name like '%my_search_string%'--use this for filtering
  ORDER BY sch.name + '.' + obj.name
                        SELECT *
FROM   sys.all_objects
WHERE  type = 'P'
       AND is_ms_shipped = 1
                        If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With