Skip to main content

external_volumes

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

Overview

Nameexternal_volumes
TypeResource
Idsnowflake.external_volume.external_volumes

Fields

NameDatatypeDescription
namestringString that specifies the identifier (the name) for the external volume; must be unique in your account.
allow_writesbooleanSpecifies whether write operations are allowed for the external volume; must be set to TRUE for Iceberg tables that use Snowflake as the catalog.
commentstringString (literal) that specifies a comment for the external volume.
created_onstringDate and time when the external volume was created.
ownerstringRole that owns the external volume
owner_role_typestringThe type of role that owns the external volume
storage_locationsarraySet of named cloud storage locations in different regions and, optionally, cloud platforms.

Methods

NameAccessible byRequired ParamsDescription
fetch_external_volumeSELECTname, endpointFetch an external volume
list_external_volumesSELECTendpointList external volumes
create_external_volumeINSERTdata__name, data__storage_locations, endpointCreate an external volume
delete_external_volumeDELETEname, endpointDelete an external volume
undrop_external_volumeEXECname, endpointUndrop an external volume

SELECT examples

List external volumes

SELECT
name,
allow_writes,
comment,
created_on,
owner,
owner_role_type,
storage_locations
FROM snowflake.external_volume.external_volumes
WHERE endpoint = '{{ endpoint }}';

INSERT example

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

/*+ create */
INSERT INTO snowflake.external_volume.external_volumes (
data__name,
data__storage_locations,
data__allow_writes,
data__comment,
endpoint
)
SELECT
'{{ name }}',
'{{ storage_locations }}',
'{{ allow_writes }}',
'{{ comment }}',
'{{ endpoint }}'
;

DELETE example

Deletes the specified external_volumes resource.

/*+ delete */
DELETE FROM snowflake.external_volume.external_volumes
WHERE name = '{{ name }}'
AND endpoint = '{{ endpoint }}';