none
List of modules in CLR RRS feed

  • Question

  • Hi all

    Is there any way to list the available Stored Procedures and Functions in an (installed) assembly? Maybe with their parameters.

    Tx.

    Thursday, November 7, 2019 4:08 PM

Answers

  • But I want to know the definitions "inside" the assembly, just after a CREATE ASSEMBLY.
    Review the source code, documentation or ask the developer which method's are available; from SQL Server side you can't get the information.

    Olaf Helper

    [ Blog] [ Xing] [ MVP]

    • Marked as answer by EgSuLu Friday, November 8, 2019 9:01 AM
    Thursday, November 7, 2019 7:38 PM

All replies

  • /*
    sys.objects.type:
    AF = Aggregate function (CLR)
    FS = Assembly (CLR) scalar-function
    FT = Assembly (CLR) table-valued function
    PC = Assembly (CLR) stored-procedure
    */
    
    SELECT *
    FROM sys.sql_modules AS m
    INNER JOIN sys.objects AS o ON o.object_id = m.object_id
    WHERE o.type IN ('AF', 'FS', 'FT', 'PC');


    A Fan of SSIS, SSRS and SSAS

    Thursday, November 7, 2019 4:40 PM
  • That works, if the objects are already created, for example CREATE PROC as EXTERNAL. But I want to know the definitions "inside" the assembly, just after a CREATE ASSEMBLY.
    Thursday, November 7, 2019 4:46 PM
  • SELECT * FROM sys.assembly_modules;

    A Fan of SSIS, SSRS and SSAS

    Thursday, November 7, 2019 4:57 PM
  • But I want to know the definitions "inside" the assembly, just after a CREATE ASSEMBLY.
    Review the source code, documentation or ask the developer which method's are available; from SQL Server side you can't get the information.

    Olaf Helper

    [ Blog] [ Xing] [ MVP]

    • Marked as answer by EgSuLu Friday, November 8, 2019 9:01 AM
    Thursday, November 7, 2019 7:38 PM