Forum Discussion
evrise
2 years agoAdvocate II
Environments (preview): how to define env variables?
Sorry for so stupid question. But I am not sure how to setup environment variables for Spark notebook/jobs. I thought Environments should solve this, but do not know how. Whats your approach ?
Anonymous
2 years agoNot applicable
Hi evrise
Thanks for using Fabric Community.
You can use the below code in your notebook to set the environment variable.
import os
os.environ['NAME_OF THE_ENVIRONMENT'] = 'true'
Hope this helps. Please let me know if you have any further questions.