Skip to main content

pipelines

Operations on a pipelines resource.

Overview

Namepipelines
TypeResource
Iddatabricks_workspace.deltalivetables.pipelines

Fields

NameDatatype
namestring
cluster_idstring
creator_user_namestring
latest_updatesarray
pipeline_idstring
run_as_user_namestring
specobject
statestring

Methods

NameAccessible byRequired ParamsDescription
getSELECTpipeline_id, deployment_name
listpipelinesSELECTdeployment_nameLists pipelines defined in the Delta Live Tables system.
createINSERTdeployment_nameCreates a new data processing pipeline based on the requested configuration. If successful, this method returns the ID of the new pipeline.
deleteDELETEpipeline_id, deployment_nameDeletes a pipeline.
updateUPDATEpipeline_id, deployment_nameUpdates a pipeline with the supplied configuration.
stopEXECpipeline_id, deployment_nameStops the pipeline by canceling the active update. If there is no active update for the pipeline, this request is a no-op.

SELECT examples

SELECT
name,
cluster_id,
creator_user_name,
latest_updates,
pipeline_id,
run_as_user_name,
spec,
state
FROM databricks_workspace.deltalivetables.pipelines
WHERE deployment_name = '{{ deployment_name }}';

INSERT example

Use the following StackQL query and manifest file to create a new pipelines resource.

/*+ create */
INSERT INTO databricks_workspace.deltalivetables.pipelines (
deployment_name,
data__continuous,
data__name,
data__clusters,
data__libraries,
data__storage
)
SELECT
'{{ deployment_name }}',
'{{ continuous }}',
'{{ name }}',
'{{ clusters }}',
'{{ libraries }}',
'{{ storage }}'
;

UPDATE example

Updates a pipelines resource.

/*+ update */
-- replace field1, field2, etc. with the fields you want to update
UPDATE databricks_workspace.deltalivetables.pipelines
SET field1 = '{{ value1 }}',
field2 = '{{ value2 }}', ...
WHERE pipeline_id = '{{ pipeline_id }}' AND
deployment_name = '{{ deployment_name }}';

DELETE example

Deletes a pipelines resource.

/*+ delete */
DELETE FROM databricks_workspace.deltalivetables.pipelines
WHERE pipeline_id = '{{ pipeline_id }}' AND
deployment_name = '{{ deployment_name }}';