Skip to main content

Create Query

Creates a query.

External Documentation

To learn more, visit the Databricks documentation.

Basic Parameters

ParameterDescription
DescriptionGeneral description that conveys additional information about this query such as usage notes.
Display NameDisplay name of the query that appears in list views, widget headings, and on the query page.
Parent PathWorkspace path of the workspace folder containing the object.For example: /Users/user@acme.com.
QueryThe query to be run.For example: SELECT 1.
Run ModeSets the "Run as" role for the object.
Warehouse IDThe ID of the SQL warehouse attached to the query. Can be obtained via the List Warehouses action.

Advanced Parameters

ParameterDescription
Apply Auto LimitWhether to apply a 1000 row limit to the query result.
CatalogName of the catalog where this query will be executed.
Query ParametersList of query parameter definitions. For further information, please refer to Databricks Documentation.For example:
[  {    "name": "foo",    "text_value": {      "value": "bar"    },    "title": "foo"  }]
SchemaName of the schema where this query will be executed.
TagsA comma separated list of tags.

Example Output

{
"description": "Example description",
"owner_user_name": "user@acme.com",
"tags": [
"Tag 1"
],
"display_name": "Example query",
"id": "fe25e731-92f2-4838-9fb2-1ca364320a3d",
"parent_path": "/Workspace/Users/user@acme.com",
"lifecycle_state": "ACTIVE",
"last_modifier_user_name": "user@acme.com",
"query_text": "SELECT 1",
"parameters": [
{
"name": "foo",
"text_value": {
"value": "bar"
},
"title": "foo"
}
],
"warehouse_id": "a7066a8ef796be84",
"run_as_mode": "OWNER",
"create_time": "2019-08-24T14:15:22Z"
}

Workflow Library Example

Create Query with Databricks and Send Results Via Email

Workflow LibraryPreview this Workflow on desktop