In synapse pipeline , i am using a notebook activity in pipeline, can i get the notebook name dynamically to a variable.

sreedevi 25 Reputation points
2023-08-03T07:44:22.1633333+00:00

In synapse pipeline , i am using a notebook activity in pipeline, can i get the notebook name dynamically to a variable.

Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
5,373 questions
{count} votes

Accepted answer
  1. QuantumCache 20,366 Reputation points Moderator
    2023-08-08T22:10:38.79+00:00

    Hello @Sreedevi, Ramagiri (Cognizant)

    Wanted to check the scenario!

    1. Wanted to pass the Notebook Name to the Notebook activity Dynamically?

    Like the below image shows? pass the Notebook name to the Activity?User's image

    1. Wanted to Know what is the Notebook Name which is being used by the Notebook Activity?

    User's image

    For scenario # 2, below tried to capture the Notebook name by using the Set-Variable.

    Below is the Expression:

    @activity('Notebook1').output.status.Output.status.livyInfo.jobCreationRequest.conf['spark.synapse.context.notebookname']
    

    User's image

    A typical Notebook activity output looks like the below image, and we can parse the output to find which Notebook was used!!!

    User's image

    Please let us know which scenario we are trying over here? thanks for your understanding.

    2 people found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. sreedevi 25 Reputation points
    2023-08-16T01:50:27.27+00:00

    Hello @SatishBoddu-MSFT,

    I have completed "Accept Answer" and short survey.
    Please let me know if any other action required from my end.

    Thank you

    1 person found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.