Using data connection snippets

As a data scientist, you can connect your project to data with a data connection snippet.

  1. Select New Project.
  2. Enter the project name.
  3. Start a new session. To use a Spark connection, make sure to select an ML Runtime engine.
  4. In the Connection Code Snippet pane, select the data connection to use.
  5. Select Copy Code.
  6. Paste the snippet into your code.
  7. Edit the username and password, if necessary. (This is not necessary for the Spark Data Lake connection, or if the WORKLOAD_PASSWORD environmental variable is set up for the user.)
  8. Enter the data connection name.
  9. Uncomment and edit the SQL query.
  10. Select Run.
The results of the SQL query display in the command window.
When you have finished exploring the available data sources, you can select Don’t show me this again for this project on the Connection Code Snippet pane, and it will no longer display when you start a session in the project.