Dec 7, 2014

How to get current SQL function or trigger name in SQL Server

We can get it by using meta data function.

Script to get the current or running SQL function name inside the function:

SELECT OBJECT_NAME(@@PROCID) AS ProcName


We must have to write above script inside the SQL function.

No comments:

Post a Comment