Synapse Notebook reference - how to use %run

alex feng 81 Reputation points

I'm trying to use the Azure Synapse notebook reference described here:

Here is my setup, notebook_1 and notebook_2 are both under root folder of Synapse notebooks. Both notebooks have been published.

I have a notebook_1 published in workspace and then trying to call it in notebook_2 using

%run 'notebook_1'

Got an error saying:

MagicUsageError: Cannot read notebook 'notebook_1'. The possible reason is that the notebook doesn't exist.

I have tried other varieties like 'notebook_1.ipynb', './notebook_1.ipynb', no luck.

Could anyone give some advice on the proper way of doing that? Many thanks.

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.
2,626 questions
No comments
{count} votes

Accepted answer
  1. Vaibhav Chaudhari 37,771 Reputation points

    Can you simply run without single quotes-



    Please don't forget to Accept Answer and Up-vote if the response helped -- Vaibhav

2 additional answers

Sort by: Most helpful
  1. Øyvind Rogne-Jensrud 1 Reputation point

    I tried. It does not work


    No comments

  2. Rodrigo de Sousa Silva 1 Reputation point

    In the notebook properties tab, there is the option to "enable unpublished notebook reference", after checking the box, it will be possible to use %run notebook_1Captura de tela 2023-01-12 121408

    No comments