Skip to main content

Databricks SQL Warehouse - Execute Query

Overview​

Quickly execute a SQL within a Databricks SQL Warehouse

NOTE This vessel will not return any files, so if you are looking to fetch data from Databricks, use the Databricks SQL Warehouse - Download Query Results to Platform Blueprint. Intended use of this blueprint is for queries with no return values (i.e. ALTER TABLE, DELETE TABLE, etc.)

Variables​

NameReferenceTypeRequiredDefaultOptionsDescription
Access TokenDATABRICKS_SQL_ACCESS_TOKENPasswordβœ…--The access token generated in Databricks for programatic access
Databricks Server HostDATABRICKS_SQL_SERVER_HOSTAlphanumericβœ…--The URL address of the SQL warehouse
Warehouse HTTP PathDATABRICKS_SQL_HTTP_PATHAlphanumericβœ…--The extended path for the SQL warehouse
CatalogDATABRICKS_SQL_CATALOGAlphanumericβž–--The optional catalog to connect to. If none is provided, this will default to Hive Metastore
SchemaDATABRICKS_SQL_SCHEMAAlphanumericβž–--The optional schema to connect to. If none is provided, the blueprint will connect to the default schema
QueryDATABRICKS_SQL_QUERYAlphanumericβœ…--The query to send to Databricks

YAML​

Below is the YAML template for this Blueprint and can be used in the Fleet YAML Editor.

source:
blueprint: Databricks SQL Warehouse - Execute Query
inputs:
DATABRICKS_SQL_ACCESS_TOKEN: null ## REQUIRED
DATABRICKS_SQL_SERVER_HOST: null ## REQUIRED
DATABRICKS_SQL_HTTP_PATH: null ## REQUIRED
DATABRICKS_SQL_CATALOG: null
DATABRICKS_SQL_SCHEMA: null
DATABRICKS_SQL_QUERY: null ## REQUIRED
type: BLUEPRINT
guardrails:
retry_count: 1
retry_wait: 0h0m0s
runtime_cutoff: 1h0m0s
exclude_exit_code_ranges:
- '200'
- '202'
- '203'
- '204'
- '205'
- '206'
- '207'
- '208'
- '209'
- '210'
- '211'
- '249'