how to pull a parameter from .sql file with dbutils.notebook.run
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-06-2025 06:56 AM
Hi,
I want to use this:
result = dbutils.notebook.run('/Workspace/Usersxxxxt', 600, {"environment": inputEnvironment})
this pulls from this .sql file in that path:
DROP TEMPORARY VARIABLE IF EXISTS strEnv;
DECLARE VARIABLE strEnv STRING;
SET VARIABLE strEnv = '${inputEnvironment}';
This works with .py file with that sql code inside, but not if the file is .sql.
Someone has an inside why is failing?
I already tested with another user, is not that I am not sure.
Thanks in advance