<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Capture fabric warehouse SP Name into a table in Data Warehouse</title>
    <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5137701#M4373</link>
    <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Inside the SP...&lt;BR /&gt;&lt;BR /&gt;SELECT TOP 1 @ProcName =&lt;BR /&gt;OBJECT_SCHEMA_NAME(s.objectid) + '.' + OBJECT_NAME(s.objectid)&lt;BR /&gt;FROM sys.dm_exec_requests r&lt;BR /&gt;CROSS APPLY sys.dm_exec_sql_text(r.sql_handle) s&lt;BR /&gt;WHERE r.session_id = @@SPID;&lt;BR /&gt;&lt;BR /&gt;insert into logtable (@ProcName, @starttime,&amp;nbsp;@endtime)&lt;BR /&gt;&lt;BR /&gt;when i select * from logtable, procname is empty since it was run via fabric pipeline.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 23 Mar 2026 15:53:10 GMT</pubDate>
    <dc:creator>AJAJ</dc:creator>
    <dc:date>2026-03-23T15:53:10Z</dc:date>
    <item>
      <title>Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5137701#M4373</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Inside the SP...&lt;BR /&gt;&lt;BR /&gt;SELECT TOP 1 @ProcName =&lt;BR /&gt;OBJECT_SCHEMA_NAME(s.objectid) + '.' + OBJECT_NAME(s.objectid)&lt;BR /&gt;FROM sys.dm_exec_requests r&lt;BR /&gt;CROSS APPLY sys.dm_exec_sql_text(r.sql_handle) s&lt;BR /&gt;WHERE r.session_id = @@SPID;&lt;BR /&gt;&lt;BR /&gt;insert into logtable (@ProcName, @starttime,&amp;nbsp;@endtime)&lt;BR /&gt;&lt;BR /&gt;when i select * from logtable, procname is empty since it was run via fabric pipeline.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Mar 2026 15:53:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5137701#M4373</guid>
      <dc:creator>AJAJ</dc:creator>
      <dc:date>2026-03-23T15:53:10Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5137879#M4379</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have used a slightly changed DMV and tested it by directly calling the procedure as well as via a pipeline, and both worked.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;/*===========================================================
  Fabric Warehouse-friendly logging table + stored procedure
  - VARCHAR columns (no NVARCHAR persisted)
  - IDENTITY without seed/increment
  - No GO (pipeline-safe)
  - No ERROR_LINE() (not supported)
  - ProcName resolved via DMVs (since @@PROCID not supported)
===========================================================*/

-- Create logging table if it doesn't exist
IF OBJECT_ID('dbo.ProcExecutionLog', 'U') IS NULL
BEGIN
    CREATE TABLE dbo.ProcExecutionLog
    (
        LogId           bigint IDENTITY NOT NULL,
        ExecutionId     uniqueidentifier NOT NULL,

        ProcName        varchar(256) NULL,
        Invoker         varchar(200) NULL,

        StartTimeUtc    datetime2(3) NOT NULL,
        EndTimeUtc      datetime2(3) NULL,
        DurationMs      bigint NULL,

        Status          varchar(20) NOT NULL,  -- STARTED | SUCCEEDED | FAILED

        ErrorNumber     int NULL,
        ErrorSeverity   int NULL,
        ErrorState      int NULL,
        ErrorProcedure  varchar(256) NULL,
        ErrorMessage    varchar(4000) NULL
    );
END;

-- Create/alter procedure in same batch
EXEC('
CREATE OR ALTER PROCEDURE dbo.usp_DoWork_WithLogging
    @Invoker varchar(200) = NULL
AS
BEGIN
    SET NOCOUNT ON;

    DECLARE @ExecutionId uniqueidentifier = NEWID();
    DECLARE @ProcName varchar(256) = NULL;

    DECLARE @StartTimeUtc datetime2(3) = SYSUTCDATETIME();
    DECLARE @EndTimeUtc   datetime2(3) = NULL;   -- declare ONCE
    DECLARE @DurationMs   bigint       = NULL;

    -- Resolve current module name using DMVs (Fabric workaround)
    -- If this returns NULL in some pipeline contexts, consider passing ProcName as a parameter instead.
    SELECT TOP (1)
        @ProcName = s.name + ''.'' + p.name
    FROM sys.dm_exec_requests r
    CROSS APPLY sys.dm_exec_sql_text(r.sql_handle) t
    INNER JOIN sys.procedures p
        ON p.object_id = t.objectid
    INNER JOIN sys.schemas s
        ON s.schema_id = p.schema_id
    WHERE r.session_id = @@SPID;

    -- Insert STARTED row
    INSERT INTO dbo.ProcExecutionLog
    (
        ExecutionId, ProcName, Invoker, StartTimeUtc, Status
    )
    VALUES
    (
        @ExecutionId, @ProcName, @Invoker, @StartTimeUtc, ''STARTED''
    );

    BEGIN TRY
        -------------------------------------------------------
        -- DO WORK HERE (replace with your real logic)
        -------------------------------------------------------
        DECLARE @Dummy int = 1;
        SET @Dummy = @Dummy + 1;
        -------------------------------------------------------

        SET @EndTimeUtc = SYSUTCDATETIME();
        SET @DurationMs = CAST(DATEDIFF(MILLISECOND, @StartTimeUtc, @EndTimeUtc) AS bigint);

        UPDATE dbo.ProcExecutionLog
        SET
            EndTimeUtc = @EndTimeUtc,
            DurationMs = @DurationMs,
            Status     = ''SUCCEEDED''
        WHERE ExecutionId = @ExecutionId;
    END TRY
    BEGIN CATCH
        SET @EndTimeUtc = SYSUTCDATETIME();
        SET @DurationMs = CAST(DATEDIFF(MILLISECOND, @StartTimeUtc, @EndTimeUtc) AS bigint);

        UPDATE dbo.ProcExecutionLog
        SET
            EndTimeUtc     = @EndTimeUtc,
            DurationMs     = @DurationMs,
            Status         = ''FAILED'',
            ErrorNumber    = ERROR_NUMBER(),
            ErrorSeverity  = ERROR_SEVERITY(),
            ErrorState     = ERROR_STATE(),
            ErrorProcedure = CAST(ERROR_PROCEDURE() AS varchar(256)),
            ErrorMessage   = CAST(ERROR_MESSAGE() AS varchar(4000))
        WHERE ExecutionId = @ExecutionId;

        THROW;
    END CATCH
END
');&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can invoke the stored procedure in a Fabric pipeline passing the pipeline id &lt;SPAN&gt;&lt;EM&gt;@pipeline().RunId&amp;nbsp;&lt;/EM&gt;and it will capture that in the log table.&amp;nbsp;&lt;!-- ScriptorEndFragment --&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Mar 2026 20:13:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5137879#M4379</guid>
      <dc:creator>deborshi_nag</dc:creator>
      <dc:date>2026-03-23T20:13:33Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5138188#M4385</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;, Thank you for reaching out to the Microsoft Community Forum.&lt;/P&gt;
&lt;P&gt;This is because your query relies on DMVs to infer the current stored procedure. In pipeline runs, the execution is often wrapped or submitted as a batch, so sys.dm_exec_requests and sys.dm_exec_sql_text don’t reliably return your procedure’s objectid. So, @ProcName comes back NULL, making your log table shows it as empty.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can’t fix this using DMVs in Fabric. I suggest you stop deriving the procedure name at runtime and instead set it explicitly, either hardcode it inside the procedure or pass it as a parameter from the pipeline. This avoids dependency on execution context, which is exactly what’s causing the issue.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Mar 2026 10:09:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5138188#M4385</guid>
      <dc:creator>v-hashadapu</dc:creator>
      <dc:date>2026-03-24T10:09:45Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5138917#M4391</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1445078" data-lia-user-login="deborshi_nag" class="lia-mention lia-mention-user"&gt;deborshi_nag&lt;/a&gt;. Unfortunately you slightly modified code still returns null via pipeline run.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My pipeline dynamically triggers SPs from ETLConfig tables. So SP name is already a parameter to pipeline.&lt;BR /&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="882992" data-lia-user-login="v-hashadapu" class="lia-mention lia-mention-user"&gt;v-hashadapu&lt;/a&gt;&amp;nbsp;you understood the issue exactly that when run via pipeline its not working. I didnt want to hardcode.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;there are 2 ways we run sp, via pipeline or for debugging/development via ssms.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;im using a simple if else conditon if parmeter via pipeline is not null, use that, else use query.&lt;BR /&gt;approach i took.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;ALSO ANY THOUGHTS ON HOW TO TRACK IF A TABLE IS USED BY A SP OR VIEW? In fabric warehouse. SQL server has view dependency when right clicked on a table. There are also dependency scripts which point out if a table is being used by a view or sp. Do by any chance know of script if a table is used by view or sp.&lt;/P&gt;</description>
      <pubDate>Wed, 25 Mar 2026 14:25:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5138917#M4391</guid>
      <dc:creator>AJAJ</dc:creator>
      <dc:date>2026-03-25T14:25:31Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5139086#M4393</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;See if this works:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DECLARE&lt;/SPAN&gt;&lt;SPAN&gt; @SchemaName &lt;/SPAN&gt;&lt;SPAN&gt;varchar&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;128&lt;/SPAN&gt;&lt;SPAN&gt;) = &lt;/SPAN&gt;&lt;SPAN&gt;'dbo'&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;DECLARE&lt;/SPAN&gt;&lt;SPAN&gt; @TableName &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;varchar&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;128&lt;/SPAN&gt;&lt;SPAN&gt;) = &lt;/SPAN&gt;&lt;SPAN&gt;'ProcExecutionLog'&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;SPAN&gt;SELECT&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;OBJECT_SCHEMA_NAME&lt;/SPAN&gt;&lt;SPAN&gt;(d.referencing_id) &lt;/SPAN&gt;&lt;SPAN&gt;AS&lt;/SPAN&gt;&lt;SPAN&gt; referencing_schema,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;OBJECT_NAME&lt;/SPAN&gt;&lt;SPAN&gt;(d.referencing_id) &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;AS&lt;/SPAN&gt;&lt;SPAN&gt; referencing_object,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; o.type_desc &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;AS&lt;/SPAN&gt;&lt;SPAN&gt; referencing_type,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; d.referenced_schema_name,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; d.referenced_entity_name&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;FROM&lt;/SPAN&gt;&lt;SPAN&gt; sys.sql_expression_dependencies d&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;JOIN&lt;/SPAN&gt;&lt;SPAN&gt; sys.objects o&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ON&lt;/SPAN&gt;&lt;SPAN&gt; d.referencing_id = o.&lt;/SPAN&gt;&lt;SPAN&gt;object_id&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;WHERE&lt;/SPAN&gt;&lt;SPAN&gt; d.referenced_schema_name = @SchemaName&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;AND&lt;/SPAN&gt;&lt;SPAN&gt; d.referenced_entity_name = @TableName&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;AND&lt;/SPAN&gt;&lt;SPAN&gt; o.type &lt;/SPAN&gt;&lt;SPAN&gt;IN&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN&gt;'V'&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;'P'&lt;/SPAN&gt;&lt;SPAN&gt;) &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;-- V = View, P = Stored Procedure&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;ORDER&lt;/SPAN&gt; &lt;SPAN&gt;BY&lt;/SPAN&gt;&lt;SPAN&gt; referencing_type, referencing_schema, referencing_object;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 25 Mar 2026 19:24:04 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5139086#M4393</guid>
      <dc:creator>deborshi_nag</dc:creator>
      <dc:date>2026-03-25T19:24:04Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5139090#M4394</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In regards to your original query, why don't you write a stored procedure that will accept a parameter, check that the value supplied matches with a stored procedure name, and if so, insert a line in the log table and run the stored procedure.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can supply you with the code if that helps. I have tried this approach, it works both when calling it directly, as well as via a pipeline activity.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Mar 2026 19:28:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5139090#M4394</guid>
      <dc:creator>deborshi_nag</dc:creator>
      <dc:date>2026-03-25T19:28:12Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5139265#M4397</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;, Thank you for reaching out to the Microsoft Community Forum.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Your IF/ELSE approach is exactly the right way to handle this. In Fabric, DMV based detection isn’t reliable in pipeline runs, so using the pipeline parameter when available and falling back to DMVs for SSMS/debug scenarios is the correct and practical pattern.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For your second question, sys.sql_expression_dependencies is the right way to track which procedures or views use a table in Fabric, but it only captures static SQL. If you’re using dynamic SQL or config-driven execution, some dependencies won’t show up there. In practice, you’ll need to combine it with a search on sys.sql_modules to catch anything missed, since Fabric doesn’t have a fully complete dependency view like SQL Server.&lt;/P&gt;</description>
      <pubDate>Thu, 26 Mar 2026 06:46:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5139265#M4397</guid>
      <dc:creator>v-hashadapu</dc:creator>
      <dc:date>2026-03-26T06:46:35Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5140781#M4414</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;SPAN data-teams="true"&gt;hope you are doing great. May we know if your issue is solved or if you are still experiencing difficulties. Please share the details as it will help the community, especially others with similar issues.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Mar 2026 05:06:47 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5140781#M4414</guid>
      <dc:creator>v-hashadapu</dc:creator>
      <dc:date>2026-03-30T05:06:47Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5141309#M4420</link>
      <description>&lt;P&gt;thanks&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="882992" data-lia-user-login="v-hashadapu" class="lia-mention lia-mention-user"&gt;v-hashadapu&lt;/a&gt;&amp;nbsp;. Yes most of SQLs are static. Do you by any chance could share the code based on the your suggestion to use&amp;nbsp;&lt;SPAN&gt;sys.sql_expression_dependencies? Object is what fabric warehouse table is used by any sp or any view.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Mar 2026 16:17:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5141309#M4420</guid>
      <dc:creator>AJAJ</dc:creator>
      <dc:date>2026-03-30T16:17:45Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5142351#M4423</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;, Thank you for reaching out to the Microsoft Community Forum.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please try this:&lt;BR /&gt;DECLARE @SchemaName sysname = 'dbo';&lt;BR /&gt;DECLARE @TableName&amp;nbsp; sysname = 'YourTableName';&lt;BR /&gt;SELECT&lt;BR /&gt;s.name&amp;nbsp; AS referencing_schema,&lt;BR /&gt;o.name&amp;nbsp; AS referencing_object,&lt;BR /&gt;o.type_desc AS referencing_type&lt;BR /&gt;FROM sys.sql_expression_dependencies d&lt;BR /&gt;JOIN sys.objects o&lt;BR /&gt;ON d.referencing_id = o.object_id&lt;BR /&gt;JOIN sys.schemas s&lt;BR /&gt;ON o.schema_id = s.schema_id&lt;BR /&gt;WHERE d.referenced_schema_name = @SchemaName&lt;BR /&gt;AND d.referenced_entity_name = @TableName&lt;BR /&gt;AND o.type IN ('P','V')&amp;nbsp; -- P = Stored Procedure, V = View&lt;BR /&gt;ORDER BY o.type_desc, s.name, o.name;&lt;/P&gt;</description>
      <pubDate>Wed, 01 Apr 2026 05:01:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5142351#M4423</guid>
      <dc:creator>v-hashadapu</dc:creator>
      <dc:date>2026-04-01T05:01:35Z</dc:date>
    </item>
    <item>
      <title>Re: Capture fabric warehouse SP Name into a table</title>
      <link>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5143952#M4435</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="694302" data-lia-user-login="AJAJ" class="lia-mention lia-mention-user"&gt;AJAJ&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;SPAN data-teams="true"&gt;Hope you're doing okay! May we know if it worked for you, or are you still experiencing difficulties? Let us know — your feedback can really help others in the same situation.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Apr 2026 05:47:54 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Data-Warehouse/Capture-fabric-warehouse-SP-Name-into-a-table/m-p/5143952#M4435</guid>
      <dc:creator>v-hashadapu</dc:creator>
      <dc:date>2026-04-06T05:47:54Z</dc:date>
    </item>
  </channel>
</rss>

