Skip to main content

managed_instance_encryption_protectors

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

Overview

Namemanaged_instance_encryption_protectors
TypeResource
Idazure.sql.managed_instance_encryption_protectors

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
autoRotationEnabledbooleanKey auto rotation opt-in flag. Either true or false.
kindstringKind of encryption protector. This is metadata used for the Azure portal experience.
serverKeyNamestringThe name of the managed instance key.
serverKeyTypestringThe encryption protector type like 'ServiceManaged', 'AzureKeyVault'. Required. Known values are: "ServiceManaged" and "AzureKeyVault". (ServiceManaged, AzureKeyVault)
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
thumbprintstringThumbprint of the server key.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
uristringThe URI of the server key.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, managed_instance_name, encryption_protector_name, subscription_idGets a managed instance encryption protector.
list_by_instanceselectresource_group_name, managed_instance_name, subscription_idGets a list of managed instance encryption protectors.
create_or_updateinsertresource_group_name, managed_instance_name, encryption_protector_name, subscription_idUpdates an existing encryption protector.
create_or_updatereplaceresource_group_name, managed_instance_name, encryption_protector_name, subscription_idUpdates an existing encryption protector.
revalidateexecresource_group_name, managed_instance_name, encryption_protector_name, subscription_idRevalidates an existing encryption protector.

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
encryption_protector_namestringThe name of the encryption protector to be retrieved. "current" Required.
managed_instance_namestringThe name of the managed instance. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring

SELECT examples

Gets a managed instance encryption protector.

SELECT
id,
name,
autoRotationEnabled,
kind,
serverKeyName,
serverKeyType,
systemData,
thumbprint,
type,
uri
FROM azure.sql.managed_instance_encryption_protectors
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND managed_instance_name = '{{ managed_instance_name }}' -- required
AND encryption_protector_name = '{{ encryption_protector_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Updates an existing encryption protector.

INSERT INTO azure.sql.managed_instance_encryption_protectors (
properties,
resource_group_name,
managed_instance_name,
encryption_protector_name,
subscription_id
)
SELECT
'{{ properties }}',
'{{ resource_group_name }}',
'{{ managed_instance_name }}',
'{{ encryption_protector_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
kind,
properties,
systemData,
type
;

REPLACE examples

Updates an existing encryption protector.

REPLACE azure.sql.managed_instance_encryption_protectors
SET
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND managed_instance_name = '{{ managed_instance_name }}' --required
AND encryption_protector_name = '{{ encryption_protector_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
kind,
properties,
systemData,
type;

Lifecycle Methods

Revalidates an existing encryption protector.

EXEC azure.sql.managed_instance_encryption_protectors.revalidate 
@resource_group_name='{{ resource_group_name }}' --required,
@managed_instance_name='{{ managed_instance_name }}' --required,
@encryption_protector_name='{{ encryption_protector_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;