|
| 1 | +# Passing Parameters to a Notebook from a Pipeline - Quick Guide |
| 2 | + |
| 3 | +Costa Rica |
| 4 | + |
| 5 | +[](https://github.com/) |
| 6 | +[brown9804](https://github.com/brown9804) |
| 7 | + |
| 8 | +Last updated: 2025-03-03 |
| 9 | + |
| 10 | +---------- |
| 11 | + |
| 12 | +<details> |
| 13 | +<summary><b>List of References </b> (Click to expand)</summary> |
| 14 | + |
| 15 | +- [What is Azure Data Factory?](https://learn.microsoft.com/en-us/azure/data-factory/introduction) |
| 16 | +- [Quickstart: Get started with Azure Data Factory](https://learn.microsoft.com/en-us/azure/data-factory/quickstart-get-started) |
| 17 | +- [Quickstart: Create a data factory by using the Azure portal](https://learn.microsoft.com/en-us/azure/data-factory/quickstart-create-data-factory) |
| 18 | + |
| 19 | +</details> |
| 20 | + |
| 21 | +## Create a Microsoft Fabric Workspace |
| 22 | + |
| 23 | +1. **Sign in to Power BI**: Go to the Power BI Service and log in. |
| 24 | +2. **Create a New Workspace**: |
| 25 | + - From the navigation pane, select `Workspaces`. |
| 26 | + - Click on `+ New workspace`. |
| 27 | + |
| 28 | + <img width="550" alt="image" src="https://github.com/user-attachments/assets/34fca476-6799-49b9-a1ce-a04384415305" /> |
| 29 | + |
| 30 | + - In the `Create a workspace` pane, enter a name for your workspace. |
| 31 | + |
| 32 | + <img width="550" alt="image" src="https://github.com/user-attachments/assets/bf18ce14-bdf1-4c5a-a15d-54fe538dba02" /> |
| 33 | + |
| 34 | + - Expand the `Advanced` section and choose either the Fabric capacity or Trial license mode. |
| 35 | + - Select `Apply` to create and open the new workspace |
| 36 | + |
| 37 | + <img width="550" alt="image" src="https://github.com/user-attachments/assets/72789bb8-1e6f-4a34-b117-3127dc0e0eb8" /> |
| 38 | + |
| 39 | +## Create a Notebook with Parameters |
| 40 | + |
| 41 | +1. Go to Your Workspace: |
| 42 | + 1. **Sign in to Power BI**: Go to the Power BI Service and log in. |
| 43 | + 2. **Navigate to Workspaces**: From the navigation pane, select `Workspaces`. |
| 44 | + 3. **Select Your Workspace**: Choose the workspace where you want to create the new item. |
| 45 | +2. Create a New Item |
| 46 | + 1. **Click on New Item**: In your workspace, click on the `New item` button. |
| 47 | + 2. **Choose the Item Type**: From the list of item types, select `Notebook`. |
| 48 | + |
| 49 | + <img width="550" alt="image" src="https://github.com/user-attachments/assets/c281bc81-7592-4f51-a4f5-20201cee2c70" /> |
| 50 | + |
| 51 | +3. Create and Configure the Notebook |
| 52 | + 1. **Provide a Name**: Enter a name for your new notebook. |
| 53 | + 2. **Configure the Notebook**: You can configure various settings for your notebook, such as the language (e.g., Python, Scala) and the environment. |
| 54 | + |
| 55 | + <img width="550" alt="image" src="https://github.com/user-attachments/assets/c9f4778c-4a64-4275-bdcd-24394484c908" /> |
| 56 | + |
| 57 | +4. Define Parameters in the Notebook |
| 58 | + 1. **Open the Notebook**: Once the notebook is created, open it. |
| 59 | + 2. **Define Parameters**: Add a cell to define the parameters you want to pass. For example: |
| 60 | + |
| 61 | + ```python |
| 62 | + # Parameters |
| 63 | + file_path = "abfss://<your-container-name>@<your-storage-account-name>.dfs.core.windows.net/<your-bronze-lakehousename>.Lakehouse/Tables/<table name>" |
| 64 | + token = "" |
| 65 | + ``` |
| 66 | + |
| 67 | +<div align="center"> |
| 68 | + <h3 style="color: #4CAF50;">Total Visitors</h3> |
| 69 | + <img src="https://profile-counter.glitch.me/brown9804/count.svg" alt="Visitor Count" style="border: 2px solid #4CAF50; border-radius: 5px; padding: 5px;"/> |
| 70 | +</div> |
0 commit comments