Skip to main content

external_metadata

Creates, updates, deletes, gets or lists an external_metadata resource.

Overview

Nameexternal_metadata
TypeResource
Iddatabricks_workspace.catalog.external_metadata

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringUnique identifier of the external metadata object.
namestring
metastore_idstringUnique identifier of parent metastore.
columnsarrayList of columns associated with the external metadata object.
create_timestringTime at which this external metadata object was created.
created_bystringUsername of external metadata object creator.
descriptionstringUser-provided free-form text description.
entity_typestringType of entity within the external system.
ownerstringOwner of the external metadata object.
propertiesobjectA map of key-value properties attached to the external metadata object.
system_typestringType of external system. (AMAZON_REDSHIFT, AZURE_SYNAPSE, CONFLUENT, DATABRICKS, GOOGLE_BIGQUERY, KAFKA, LOOKER, MICROSOFT_FABRIC, MICROSOFT_SQL_SERVER, MONGODB, MYSQL, ORACLE, OTHER, POSTGRESQL, POWER_BI, SALESFORCE, SAP, SERVICENOW, SNOWFLAKE, STREAM_NATIVE, TABLEAU, TERADATA, WORKDAY)
update_timestringTime at which this external metadata object was last modified.
updated_bystringUsername of user who last modified external metadata object.
urlstringURL associated with the external metadata object.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectname, deployment_nameGets the specified external metadata object in a metastore. The caller must be a metastore admin, the
listselectdeployment_namepage_size, page_tokenGets an array of external metadata objects in the metastore. If the caller is the metastore admin, all
createinsertdeployment_name, external_metadataCreates a new external metadata object in the parent metastore if the caller is a metastore admin or
updateupdatename, update_mask, deployment_name, external_metadataUpdates the external metadata object that matches the supplied name. The caller can only update either
deletedeletename, deployment_nameDeletes the external metadata object that matches the supplied name. The caller must be a metastore

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
deployment_namestringThe Databricks Workspace Deployment Name (default: dbc-abcd0123-a1bc)
namestringstr
update_maskstring
page_sizeintegerSpecifies the maximum number of external metadata objects to return in a single response. The value must be less than or equal to 1000.
page_tokenstringOpaque pagination token to go to next page based on previous query.

SELECT examples

Gets the specified external metadata object in a metastore. The caller must be a metastore admin, the

SELECT
id,
name,
metastore_id,
columns,
create_time,
created_by,
description,
entity_type,
owner,
properties,
system_type,
update_time,
updated_by,
url
FROM databricks_workspace.catalog.external_metadata
WHERE name = '{{ name }}' -- required
AND deployment_name = '{{ deployment_name }}' -- required
;

INSERT examples

Creates a new external metadata object in the parent metastore if the caller is a metastore admin or

INSERT INTO databricks_workspace.catalog.external_metadata (
external_metadata,
deployment_name
)
SELECT
'{{ external_metadata }}' /* required */,
'{{ deployment_name }}'
RETURNING
id,
name,
metastore_id,
columns,
create_time,
created_by,
description,
entity_type,
owner,
properties,
system_type,
update_time,
updated_by,
url
;

UPDATE examples

Updates the external metadata object that matches the supplied name. The caller can only update either

UPDATE databricks_workspace.catalog.external_metadata
SET
external_metadata = '{{ external_metadata }}'
WHERE
name = '{{ name }}' --required
AND update_mask = '{{ update_mask }}' --required
AND deployment_name = '{{ deployment_name }}' --required
AND external_metadata = '{{ external_metadata }}' --required
RETURNING
id,
name,
metastore_id,
columns,
create_time,
created_by,
description,
entity_type,
owner,
properties,
system_type,
update_time,
updated_by,
url;

DELETE examples

Deletes the external metadata object that matches the supplied name. The caller must be a metastore

DELETE FROM databricks_workspace.catalog.external_metadata
WHERE name = '{{ name }}' --required
AND deployment_name = '{{ deployment_name }}' --required
;