Skip to main content

lakeview_subscriptions

Creates, updates, deletes, gets or lists a lakeview_subscriptions resource.

Overview

Namelakeview_subscriptions
TypeResource
Iddatabricks_workspace.dashboards.lakeview_subscriptions

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
created_by_user_idintegerUserId of the user who adds subscribers (users or notification destinations) to the dashboard's schedule.
dashboard_idstringUUID identifying the dashboard to which the subscription belongs.
schedule_idstringUUID identifying the schedule to which the subscription belongs.
subscription_idstringUUID identifying the subscription.
create_timestringA timestamp indicating when the subscription was created.
etagstringThe etag for the subscription. Must be left empty on create, can be optionally provided on delete to ensure that the subscription has not been deleted since the last read.
subscriberobject
update_timestringA timestamp indicating when the subscription was last updated.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectdashboard_id, schedule_id, subscription_id, deployment_nameGet schedule subscription.
listselectdashboard_id, schedule_id, deployment_namepage_size, page_tokenList schedule subscriptions.
createinsertdashboard_id, schedule_id, deployment_name, subscriptionCreate schedule subscription.
deletedeletedashboard_id, schedule_id, subscription_id, deployment_nameetagDelete schedule subscription.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
dashboard_idstringUUID identifying the dashboard which the subscription belongs.
deployment_namestringThe Databricks Workspace Deployment Name (default: dbc-abcd0123-a1bc)
schedule_idstringUUID identifying the schedule which the subscription belongs.
subscription_idstringUUID identifying the subscription.
etagstringThe etag for the subscription. Can be optionally provided to ensure that the subscription has not been modified since the last read.
page_sizeintegerThe number of subscriptions to return per page.
page_tokenstringA page token, received from a previous ListSubscriptions call. Use this to retrieve the subsequent page.

SELECT examples

Get schedule subscription.

SELECT
created_by_user_id,
dashboard_id,
schedule_id,
subscription_id,
create_time,
etag,
subscriber,
update_time
FROM databricks_workspace.dashboards.lakeview_subscriptions
WHERE dashboard_id = '{{ dashboard_id }}' -- required
AND schedule_id = '{{ schedule_id }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
AND deployment_name = '{{ deployment_name }}' -- required
;

INSERT examples

Create schedule subscription.

INSERT INTO databricks_workspace.dashboards.lakeview_subscriptions (
subscription,
dashboard_id,
schedule_id,
deployment_name
)
SELECT
'{{ subscription }}' /* required */,
'{{ dashboard_id }}',
'{{ schedule_id }}',
'{{ deployment_name }}'
RETURNING
created_by_user_id,
dashboard_id,
schedule_id,
subscription_id,
create_time,
etag,
subscriber,
update_time
;

DELETE examples

Delete schedule subscription.

DELETE FROM databricks_workspace.dashboards.lakeview_subscriptions
WHERE dashboard_id = '{{ dashboard_id }}' --required
AND schedule_id = '{{ schedule_id }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND deployment_name = '{{ deployment_name }}' --required
AND etag = '{{ etag }}'
;