Variables passed from ADF to Databricks Notebook Try-Catch are not accessible
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-17-2024 07:12 AM - edited 04-17-2024 07:18 AM
Dear Members,
I need your help in below scenario.
I am passing few parameters from ADF pipeline to Databricks notebook.
If I execute ADF pipeline to run my databricks notebook and use these variables as is in my code (python) then it works fine.
But as soon as I use Try and catch block in my notebook then these variables which are passed from ADF pipeline, it does not recognize these variables. I can still print value of those variables outside the Try-Catch block but not inside Try-Catch.
Can you please suggest how can I proceed or access the variables which are passed by ADF inside the Try-Catch blocks of databricks notebook?
Note: This issue happens only if I run my databricks notebook through ADF pipeline. If I assign values in notebooks and run standalone notebook then it works.
Thank you for your help!
- Labels:
-
Delta Lake
-
Spark
-
Workflows
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-17-2024 07:18 AM
Hi @Abhi0607
Can you please help me to find if you are taking or defining these parameter value outside try catch or inside it ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-17-2024 10:04 AM
Parameters are defined in ADF and transferred to databricks so it is outside try catch

