How to get the full stored procedure name (incl. schema name) within the current executing stored procedure.

  Here is a function you can use to get the full stored procedure name (incl. schema name) within the current executing stored procedure:   if object_id(‘dbo.GetFullSprocName’) is not null begin drop function dbo.GetFullSprocName end go create function dbo.GetFullSprocName (@sprocId int) returns varchar(255) as begin declare @FullSprocName as varchar(255) set …