<?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 DLT PipelineID/PipleLineName values from the TASK1 should get passed to TASK2 notebook (Non-DLT) in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98316#M39686</link>
    <description>&lt;P&gt;DLT PipelineID/PipleLineName values from the TASK1 should get passed to TASK2 notebook (Non-DLT)&lt;/P&gt;&lt;P&gt;TASK1(DLT)---&amp;gt; TASK2(Non-DLT)&lt;/P&gt;&lt;P&gt;How to pass the parameters to TASK2 from TASK1. I need to get the DLT task notebook pipelineID,pipelineName and pass to TASK2 notebook parameters?&lt;/P&gt;&lt;P&gt;Need help currently, the below NOT worked&lt;/P&gt;&lt;P&gt;pipeline_id = dbutils.jobs.taskContext().pipelineId()&lt;BR /&gt;pipeline_name = dbutils.jobs.taskContext().pipelineName()&lt;/P&gt;</description>
    <pubDate>Mon, 11 Nov 2024 11:24:37 GMT</pubDate>
    <dc:creator>skumarrm</dc:creator>
    <dc:date>2024-11-11T11:24:37Z</dc:date>
    <item>
      <title>DLT PipelineID/PipleLineName values from the TASK1 should get passed to TASK2 notebook (Non-DLT)</title>
      <link>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98316#M39686</link>
      <description>&lt;P&gt;DLT PipelineID/PipleLineName values from the TASK1 should get passed to TASK2 notebook (Non-DLT)&lt;/P&gt;&lt;P&gt;TASK1(DLT)---&amp;gt; TASK2(Non-DLT)&lt;/P&gt;&lt;P&gt;How to pass the parameters to TASK2 from TASK1. I need to get the DLT task notebook pipelineID,pipelineName and pass to TASK2 notebook parameters?&lt;/P&gt;&lt;P&gt;Need help currently, the below NOT worked&lt;/P&gt;&lt;P&gt;pipeline_id = dbutils.jobs.taskContext().pipelineId()&lt;BR /&gt;pipeline_name = dbutils.jobs.taskContext().pipelineName()&lt;/P&gt;</description>
      <pubDate>Mon, 11 Nov 2024 11:24:37 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98316#M39686</guid>
      <dc:creator>skumarrm</dc:creator>
      <dc:date>2024-11-11T11:24:37Z</dc:date>
    </item>
    <item>
      <title>Re: DLT PipelineID/PipleLineName values from the TASK1 should get passed to TASK2 notebook (Non-DLT)</title>
      <link>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98329#M39695</link>
      <description>&lt;P&gt;&lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/130220"&gt;@skumarrm&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Please try the below:&lt;/P&gt;
&lt;P class="p1"&gt;&lt;STRONG&gt;Set Up Task Parameters&lt;/STRONG&gt;:&lt;/P&gt;
&lt;UL class="ul1"&gt;
&lt;UL class="ul1"&gt;
&lt;LI class="li1"&gt;In the job configuration, you can set up task parameters to pass values from one task to another.&lt;/LI&gt;
&lt;LI class="li1"&gt;For TASK1 (DLT), ensure it outputs the&amp;nbsp;PipelineID&amp;nbsp;or&amp;nbsp;PipelineName.&lt;/LI&gt;
&lt;/UL&gt;
&lt;/UL&gt;
&lt;P class="p1"&gt;&lt;STRONG&gt;Use Task Parameters in TASK2&lt;/STRONG&gt;:&lt;/P&gt;
&lt;UL class="ul1"&gt;
&lt;UL class="ul1"&gt;
&lt;LI class="li1"&gt;In the notebook for TASK2, use the&amp;nbsp;dbutils.widgets&amp;nbsp;API to retrieve the parameters passed from TASK1.&lt;/LI&gt;
&lt;/UL&gt;
&lt;/UL&gt;
&lt;P class="p1"&gt;Here’s an example of how you can set this up:&lt;/P&gt;
&lt;P class="p1"&gt;&lt;STRONG&gt;TASK1 (DLT Pipeline)&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL class="ul1"&gt;
&lt;LI class="li1"&gt;Ensure your DLT pipeline is configured and running.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P class="p1"&gt;&lt;STRONG&gt;TASK2 (Non-DLT Notebook)&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL class="ul1"&gt;
&lt;LI class="li1"&gt;Create a notebook with the following code to retrieve the parameters:&lt;/LI&gt;
&lt;/UL&gt;
&lt;P class="p1"&gt;#&amp;nbsp;Retrieve&amp;nbsp;the&amp;nbsp;PipelineID&amp;nbsp;or&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;PipelineName&amp;nbsp;passed&amp;nbsp;from&amp;nbsp;TASK1&lt;/P&gt;
&lt;P class="p1"&gt;pipeline_id&amp;nbsp;=&amp;nbsp;dbutils.widgets.get&lt;/P&gt;
&lt;P class="p1"&gt;("PipelineID")&lt;/P&gt;
&lt;P class="p1"&gt;pipeline_name&amp;nbsp;=&amp;nbsp;dbutils.widgets.get&lt;/P&gt;
&lt;P class="p1"&gt;("PipelineName")&lt;/P&gt;
&lt;P class="p1"&gt;#&amp;nbsp;Use&amp;nbsp;the&amp;nbsp;parameters&amp;nbsp;in&amp;nbsp;your&amp;nbsp;notebook&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;logic&lt;/P&gt;
&lt;P class="p1"&gt;print(f"PipelineID:&amp;nbsp;{pipeline_id}")&lt;/P&gt;
&lt;P class="p1"&gt;print(f"PipelineName:&amp;nbsp;{pipeline_name}")&lt;/P&gt;
&lt;P class="p1"&gt;#&amp;nbsp;Your&amp;nbsp;notebook&amp;nbsp;logic&amp;nbsp;here&lt;/P&gt;
&lt;P class="p1"&gt;&lt;STRONG&gt;Job Configuration&lt;/STRONG&gt;&lt;/P&gt;
&lt;UL class="ul1"&gt;
&lt;LI class="li1"&gt;In the job configuration, set up TASK1 to run the DLT pipeline.&lt;/LI&gt;
&lt;LI class="li1"&gt;Add TASK2 and configure it to run the notebook created above.&lt;/LI&gt;
&lt;LI class="li1"&gt;In the task settings for TASK2, add parameters to retrieve the&amp;nbsp;PipelineID&amp;nbsp;and&amp;nbsp;PipelineName&amp;nbsp;from TASK1.&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Mon, 11 Nov 2024 12:54:01 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98329#M39695</guid>
      <dc:creator>MuthuLakshmi</dc:creator>
      <dc:date>2024-11-11T12:54:01Z</dc:date>
    </item>
    <item>
      <title>Re: DLT PipelineID/PipleLineName values from the TASK1 should get passed to TASK2 notebook (Non-DLT)</title>
      <link>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98342#M39700</link>
      <description>&lt;P&gt;Thank you &lt;a href="https://community.databricks.com/t5/user/viewprofilepage/user-id/89478"&gt;@MuthuLakshmi&lt;/a&gt;&amp;nbsp;for sharing your inputs. Hope I followed it and again got a error -&amp;nbsp;&lt;SPAN&gt; Failed to resolve references: Task value referenced by 'tasks.DLT.values.pipeline_id' was not found.&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;I have attached the screenshots of the notebook logic.&lt;/P&gt;&lt;P&gt;Step 1:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;DLT_notebook:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;In command 3,&lt;/P&gt;&lt;P&gt;&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;&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;&amp;nbsp;&amp;nbsp; We are assigning the id to pipeline_id variable and to pass the value in the job task parameter (pipeline_id)&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sriram_kumar_0-1731333850989.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12811iDDBC7F455C6054B0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sriram_kumar_0-1731333850989.png" alt="sriram_kumar_0-1731333850989.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Non_DLT notebook:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;We are getting the value from the DLT notebook passed through task parameter.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sriram_kumar_1-1731333874132.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12812iFFB2ACF0ECF5186D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sriram_kumar_1-1731333874132.png" alt="sriram_kumar_1-1731333874132.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Step 2:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;In the job configuration setting the parameter to take the value from the DLT notebook.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sriram_kumar_2-1731333890058.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12813i698D1F0207B17C92/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sriram_kumar_2-1731333890058.png" alt="sriram_kumar_2-1731333890058.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The job failed with the error below:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sriram_kumar_3-1731333901735.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12814i043E3B04863678FB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sriram_kumar_3-1731333901735.png" alt="sriram_kumar_3-1731333901735.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sriram_kumar_4-1731333908247.png" style="width: 400px;"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/12815iB09C0CE067761635/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sriram_kumar_4-1731333908247.png" alt="sriram_kumar_4-1731333908247.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;When we checked with other people who worked in DLT, they told dbutils.job.taskValues will not work in DLT pipeline.&lt;/P&gt;&lt;P&gt;Could you please help on this and kindly let us know if we I'm missing something.&lt;BR /&gt;Thank you in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 11 Nov 2024 14:21:07 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/dlt-pipelineid-piplelinename-values-from-the-task1-should-get/m-p/98342#M39700</guid>
      <dc:creator>sriram_kumar</dc:creator>
      <dc:date>2024-11-11T14:21:07Z</dc:date>
    </item>
  </channel>
</rss>

