Skip to main content

tags

Creates, updates, deletes or gets a tag resource or lists tags in a region

Overview

Nametags
TypeResource
DescriptionA resource schema representing a Lake Formation Tag.
Idawscc.lakeformation.tags

Fields

NameDatatypeDescription
catalog_idstringThe identifier for the Data Catalog. By default, the account ID. The Data Catalog is the persistent metadata store. It contains database definitions, table definitions, and other control information to manage your Lake Formation environment.
tag_keystringThe key-name for the LF-tag.
tag_valuesarrayA list of possible values an attribute can take.
regionstringAWS region.

For more information, see AWS::LakeFormation::Tag.

Methods

NameResourceAccessible byRequired Params
create_resourcetagsINSERTTagKey, TagValues, region
delete_resourcetagsDELETEIdentifier, region
update_resourcetagsUPDATEIdentifier, PatchDocument, region
list_resourcestags_list_onlySELECTregion
get_resourcetagsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual tag.

SELECT
region,
catalog_id,
tag_key,
tag_values
FROM awscc.lakeformation.tags
WHERE
region = 'us-east-1' AND
Identifier = '{{ tag_key }}';

INSERT example

Use the following StackQL query and manifest file to create a new tag resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.lakeformation.tags (
TagKey,
TagValues,
region
)
SELECT
'{{ tag_key }}',
'{{ tag_values }}',
'{{ region }}';

UPDATE example

Use the following StackQL query and manifest file to update a tag resource, using stack-deploy.

/*+ update */
UPDATE awscc.lakeformation.tags
SET PatchDocument = string('{{ {
"TagValues": tag_values
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ tag_key }}';

DELETE example

/*+ delete */
DELETE FROM awscc.lakeformation.tags
WHERE
Identifier = '{{ tag_key }}' AND
region = 'us-east-1';

Permissions

To operate on the tags resource, the following permissions are required:

lakeformation:CreateLFTag,
lakeformation:GetLFTag