title: How to use dbutils command in pyspark job other than NoteBook
body: <p>I want to use dbutils command for accessing secrets in my pyspark job submitting through Spark-Submit inside Jobs on Databricks. While using dbutils command it is giving error dbutils not defined.</p>
  
  <p>Is there is the way to use dbutils in a pyspark job other than a notebook?</p>
  
  <p>Tried the following solutions:</p>
  
  <p>1) import DBUtils, according to this <a href="https://stackoverflow.com/a/52947713/11824257">solution</a>. But this is not Databricks dbutils.</p>
  
  <p>2) import pyspark.dbutils import DBUtils , according to this <a href="https://docs.microsoft.com/en-gb/azure/databricks/dev-tools/databricks-connect#access-dbutils" rel="nofollow noreferrer">solution</a>. But this also didn't work.</p>
  
  <p>pyspark job as shown in below diagram:
  <a href="https://i.stack.imgur.com/V3FEm.png" rel="nofollow noreferrer">image</a></p>