Skip to main content

managed_database_sensitivity_labels

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

Overview

Namemanaged_database_sensitivity_labels
TypeResource
Idazure.sql.managed_database_sensitivity_labels

Fields

NameDatatypeDescription
columnNametextfield from the properties object
column_nametextfield from the properties object
databaseNametextfield from the properties object
information_typetextfield from the properties object
information_type_idtextfield from the properties object
is_disabledtextfield from the properties object
label_idtextfield from the properties object
label_nametextfield from the properties object
managedInstanceNametextfield from the properties object
managed_bytextfield from the properties object
ranktextfield from the properties object
resourceGroupNametextfield from the properties object
schemaNametextfield from the properties object
schema_nametextfield from the properties object
sensitivityLabelSourcetextfield from the properties object
subscriptionIdtextfield from the properties object
tableNametextfield from the properties object
table_nametextfield from the properties object

Methods

NameAccessible byRequired ParamsDescription
getSELECTcolumnName, databaseName, managedInstanceName, resourceGroupName, schemaName, sensitivityLabelSource, subscriptionId, tableNameGets the sensitivity label of a given column
create_or_updateINSERTcolumnName, databaseName, managedInstanceName, resourceGroupName, schemaName, sensitivityLabelSource, subscriptionId, tableNameCreates or updates the sensitivity label of a given column
deleteDELETEcolumnName, databaseName, managedInstanceName, resourceGroupName, schemaName, sensitivityLabelSource, subscriptionId, tableNameDeletes the sensitivity label of a given column
updateUPDATEdatabaseName, managedInstanceName, resourceGroupName, subscriptionIdUpdate sensitivity labels of a given database using an operations batch.
disable_recommendationEXECcolumnName, databaseName, managedInstanceName, resourceGroupName, schemaName, sensitivityLabelSource, subscriptionId, tableNameDisables sensitivity recommendations on a given column
enable_recommendationEXECcolumnName, databaseName, managedInstanceName, resourceGroupName, schemaName, sensitivityLabelSource, subscriptionId, tableNameEnables sensitivity recommendations on a given column (recommendations are enabled by default on all columns)

SELECT examples

Gets the sensitivity label of a given column

SELECT
columnName,
column_name,
databaseName,
information_type,
information_type_id,
is_disabled,
label_id,
label_name,
managedInstanceName,
managed_by,
rank,
resourceGroupName,
schemaName,
schema_name,
sensitivityLabelSource,
subscriptionId,
tableName,
table_name
FROM azure.sql.vw_managed_database_sensitivity_labels
WHERE columnName = '{{ columnName }}'
AND databaseName = '{{ databaseName }}'
AND managedInstanceName = '{{ managedInstanceName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND schemaName = '{{ schemaName }}'
AND sensitivityLabelSource = '{{ sensitivityLabelSource }}'
AND subscriptionId = '{{ subscriptionId }}'
AND tableName = '{{ tableName }}';

INSERT example

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

/*+ create */
INSERT INTO azure.sql.managed_database_sensitivity_labels (
columnName,
databaseName,
managedInstanceName,
resourceGroupName,
schemaName,
sensitivityLabelSource,
subscriptionId,
tableName,
properties
)
SELECT
'{{ columnName }}',
'{{ databaseName }}',
'{{ managedInstanceName }}',
'{{ resourceGroupName }}',
'{{ schemaName }}',
'{{ sensitivityLabelSource }}',
'{{ subscriptionId }}',
'{{ tableName }}',
'{{ properties }}'
;

UPDATE example

Updates a managed_database_sensitivity_labels resource.

/*+ update */
UPDATE azure.sql.managed_database_sensitivity_labels
SET
operations = '{{ operations }}'
WHERE
databaseName = '{{ databaseName }}'
AND managedInstanceName = '{{ managedInstanceName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';

DELETE example

Deletes the specified managed_database_sensitivity_labels resource.

/*+ delete */
DELETE FROM azure.sql.managed_database_sensitivity_labels
WHERE columnName = '{{ columnName }}'
AND databaseName = '{{ databaseName }}'
AND managedInstanceName = '{{ managedInstanceName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND schemaName = '{{ schemaName }}'
AND sensitivityLabelSource = '{{ sensitivityLabelSource }}'
AND subscriptionId = '{{ subscriptionId }}'
AND tableName = '{{ tableName }}';