1. Packages
  2. Azure Native
  3. API Docs
  4. sql
  5. ManagedDatabaseSensitivityLabel
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Azure Native v3.1.0 published on Tuesday, Apr 8, 2025 by Pulumi

azure-native.sql.ManagedDatabaseSensitivityLabel

Explore with Pulumi AI

A sensitivity label.

Uses Azure REST API version 2023-08-01. In version 2.x of the Azure Native provider, it used API version 2021-11-01.

Other available API versions: 2018-06-01-preview, 2020-02-02-preview, 2020-08-01-preview, 2020-11-01-preview, 2021-02-01-preview, 2021-05-01-preview, 2021-08-01-preview, 2021-11-01, 2021-11-01-preview, 2022-02-01-preview, 2022-05-01-preview, 2022-08-01-preview, 2022-11-01-preview, 2023-02-01-preview, 2023-05-01-preview, 2023-08-01-preview, 2024-05-01-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native sql [ApiVersion]. See the version guide for details.

Example Usage

Updates or creates a sensitivity label of a given column with all parameters in a managed database

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;

return await Deployment.RunAsync(() => 
{
    var managedDatabaseSensitivityLabel = new AzureNative.Sql.ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabel", new()
    {
        ClientClassificationSource = AzureNative.Sql.ClientClassificationSource.Native,
        ColumnName = "myColumn",
        DatabaseName = "myDatabase",
        InformationType = "PhoneNumber",
        InformationTypeId = "d22fa6e9-5ee4-3bde-4c2b-a409604c4646",
        LabelId = "bf91e08c-f4f0-478a-b016-25164b2a65ff",
        LabelName = "PII",
        ManagedInstanceName = "myManagedInstanceName",
        Rank = AzureNative.Sql.SensitivityLabelRank.High,
        ResourceGroupName = "myRG",
        SchemaName = "dbo",
        SensitivityLabelSource = "current",
        TableName = "myTable",
    });

});
Copy
package main

import (
	sql "github.com/pulumi/pulumi-azure-native-sdk/sql/v3"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := sql.NewManagedDatabaseSensitivityLabel(ctx, "managedDatabaseSensitivityLabel", &sql.ManagedDatabaseSensitivityLabelArgs{
			ClientClassificationSource: pulumi.String(sql.ClientClassificationSourceNative),
			ColumnName:                 pulumi.String("myColumn"),
			DatabaseName:               pulumi.String("myDatabase"),
			InformationType:            pulumi.String("PhoneNumber"),
			InformationTypeId:          pulumi.String("d22fa6e9-5ee4-3bde-4c2b-a409604c4646"),
			LabelId:                    pulumi.String("bf91e08c-f4f0-478a-b016-25164b2a65ff"),
			LabelName:                  pulumi.String("PII"),
			ManagedInstanceName:        pulumi.String("myManagedInstanceName"),
			Rank:                       sql.SensitivityLabelRankHigh,
			ResourceGroupName:          pulumi.String("myRG"),
			SchemaName:                 pulumi.String("dbo"),
			SensitivityLabelSource:     pulumi.String("current"),
			TableName:                  pulumi.String("myTable"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.sql.ManagedDatabaseSensitivityLabel;
import com.pulumi.azurenative.sql.ManagedDatabaseSensitivityLabelArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var managedDatabaseSensitivityLabel = new ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabel", ManagedDatabaseSensitivityLabelArgs.builder()
            .clientClassificationSource("Native")
            .columnName("myColumn")
            .databaseName("myDatabase")
            .informationType("PhoneNumber")
            .informationTypeId("d22fa6e9-5ee4-3bde-4c2b-a409604c4646")
            .labelId("bf91e08c-f4f0-478a-b016-25164b2a65ff")
            .labelName("PII")
            .managedInstanceName("myManagedInstanceName")
            .rank("High")
            .resourceGroupName("myRG")
            .schemaName("dbo")
            .sensitivityLabelSource("current")
            .tableName("myTable")
            .build());

    }
}
Copy
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";

const managedDatabaseSensitivityLabel = new azure_native.sql.ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabel", {
    clientClassificationSource: azure_native.sql.ClientClassificationSource.Native,
    columnName: "myColumn",
    databaseName: "myDatabase",
    informationType: "PhoneNumber",
    informationTypeId: "d22fa6e9-5ee4-3bde-4c2b-a409604c4646",
    labelId: "bf91e08c-f4f0-478a-b016-25164b2a65ff",
    labelName: "PII",
    managedInstanceName: "myManagedInstanceName",
    rank: azure_native.sql.SensitivityLabelRank.High,
    resourceGroupName: "myRG",
    schemaName: "dbo",
    sensitivityLabelSource: "current",
    tableName: "myTable",
});
Copy
import pulumi
import pulumi_azure_native as azure_native

managed_database_sensitivity_label = azure_native.sql.ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabel",
    client_classification_source=azure_native.sql.ClientClassificationSource.NATIVE,
    column_name="myColumn",
    database_name="myDatabase",
    information_type="PhoneNumber",
    information_type_id="d22fa6e9-5ee4-3bde-4c2b-a409604c4646",
    label_id="bf91e08c-f4f0-478a-b016-25164b2a65ff",
    label_name="PII",
    managed_instance_name="myManagedInstanceName",
    rank=azure_native.sql.SensitivityLabelRank.HIGH,
    resource_group_name="myRG",
    schema_name="dbo",
    sensitivity_label_source="current",
    table_name="myTable")
Copy
resources:
  managedDatabaseSensitivityLabel:
    type: azure-native:sql:ManagedDatabaseSensitivityLabel
    properties:
      clientClassificationSource: Native
      columnName: myColumn
      databaseName: myDatabase
      informationType: PhoneNumber
      informationTypeId: d22fa6e9-5ee4-3bde-4c2b-a409604c4646
      labelId: bf91e08c-f4f0-478a-b016-25164b2a65ff
      labelName: PII
      managedInstanceName: myManagedInstanceName
      rank: High
      resourceGroupName: myRG
      schemaName: dbo
      sensitivityLabelSource: current
      tableName: myTable
Copy

Create ManagedDatabaseSensitivityLabel Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new ManagedDatabaseSensitivityLabel(name: string, args: ManagedDatabaseSensitivityLabelArgs, opts?: CustomResourceOptions);
@overload
def ManagedDatabaseSensitivityLabel(resource_name: str,
                                    args: ManagedDatabaseSensitivityLabelArgs,
                                    opts: Optional[ResourceOptions] = None)

@overload
def ManagedDatabaseSensitivityLabel(resource_name: str,
                                    opts: Optional[ResourceOptions] = None,
                                    managed_instance_name: Optional[str] = None,
                                    column_name: Optional[str] = None,
                                    database_name: Optional[str] = None,
                                    table_name: Optional[str] = None,
                                    schema_name: Optional[str] = None,
                                    resource_group_name: Optional[str] = None,
                                    information_type: Optional[str] = None,
                                    label_name: Optional[str] = None,
                                    rank: Optional[SensitivityLabelRank] = None,
                                    label_id: Optional[str] = None,
                                    information_type_id: Optional[str] = None,
                                    sensitivity_label_source: Optional[str] = None,
                                    client_classification_source: Optional[Union[str, ClientClassificationSource]] = None)
func NewManagedDatabaseSensitivityLabel(ctx *Context, name string, args ManagedDatabaseSensitivityLabelArgs, opts ...ResourceOption) (*ManagedDatabaseSensitivityLabel, error)
public ManagedDatabaseSensitivityLabel(string name, ManagedDatabaseSensitivityLabelArgs args, CustomResourceOptions? opts = null)
public ManagedDatabaseSensitivityLabel(String name, ManagedDatabaseSensitivityLabelArgs args)
public ManagedDatabaseSensitivityLabel(String name, ManagedDatabaseSensitivityLabelArgs args, CustomResourceOptions options)
type: azure-native:sql:ManagedDatabaseSensitivityLabel
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. ManagedDatabaseSensitivityLabelArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. ManagedDatabaseSensitivityLabelArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. ManagedDatabaseSensitivityLabelArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. ManagedDatabaseSensitivityLabelArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. ManagedDatabaseSensitivityLabelArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var managedDatabaseSensitivityLabelResource = new AzureNative.Sql.ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabelResource", new()
{
    ManagedInstanceName = "string",
    ColumnName = "string",
    DatabaseName = "string",
    TableName = "string",
    SchemaName = "string",
    ResourceGroupName = "string",
    InformationType = "string",
    LabelName = "string",
    Rank = AzureNative.Sql.SensitivityLabelRank.None,
    LabelId = "string",
    InformationTypeId = "string",
    SensitivityLabelSource = "string",
    ClientClassificationSource = "string",
});
Copy
example, err := sql.NewManagedDatabaseSensitivityLabel(ctx, "managedDatabaseSensitivityLabelResource", &sql.ManagedDatabaseSensitivityLabelArgs{
	ManagedInstanceName:        pulumi.String("string"),
	ColumnName:                 pulumi.String("string"),
	DatabaseName:               pulumi.String("string"),
	TableName:                  pulumi.String("string"),
	SchemaName:                 pulumi.String("string"),
	ResourceGroupName:          pulumi.String("string"),
	InformationType:            pulumi.String("string"),
	LabelName:                  pulumi.String("string"),
	Rank:                       sql.SensitivityLabelRankNone,
	LabelId:                    pulumi.String("string"),
	InformationTypeId:          pulumi.String("string"),
	SensitivityLabelSource:     pulumi.String("string"),
	ClientClassificationSource: pulumi.String("string"),
})
Copy
var managedDatabaseSensitivityLabelResource = new ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabelResource", ManagedDatabaseSensitivityLabelArgs.builder()
    .managedInstanceName("string")
    .columnName("string")
    .databaseName("string")
    .tableName("string")
    .schemaName("string")
    .resourceGroupName("string")
    .informationType("string")
    .labelName("string")
    .rank("None")
    .labelId("string")
    .informationTypeId("string")
    .sensitivityLabelSource("string")
    .clientClassificationSource("string")
    .build());
Copy
managed_database_sensitivity_label_resource = azure_native.sql.ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabelResource",
    managed_instance_name="string",
    column_name="string",
    database_name="string",
    table_name="string",
    schema_name="string",
    resource_group_name="string",
    information_type="string",
    label_name="string",
    rank=azure_native.sql.SensitivityLabelRank.NONE,
    label_id="string",
    information_type_id="string",
    sensitivity_label_source="string",
    client_classification_source="string")
Copy
const managedDatabaseSensitivityLabelResource = new azure_native.sql.ManagedDatabaseSensitivityLabel("managedDatabaseSensitivityLabelResource", {
    managedInstanceName: "string",
    columnName: "string",
    databaseName: "string",
    tableName: "string",
    schemaName: "string",
    resourceGroupName: "string",
    informationType: "string",
    labelName: "string",
    rank: azure_native.sql.SensitivityLabelRank.None,
    labelId: "string",
    informationTypeId: "string",
    sensitivityLabelSource: "string",
    clientClassificationSource: "string",
});
Copy
type: azure-native:sql:ManagedDatabaseSensitivityLabel
properties:
    clientClassificationSource: string
    columnName: string
    databaseName: string
    informationType: string
    informationTypeId: string
    labelId: string
    labelName: string
    managedInstanceName: string
    rank: None
    resourceGroupName: string
    schemaName: string
    sensitivityLabelSource: string
    tableName: string
Copy

ManagedDatabaseSensitivityLabel Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The ManagedDatabaseSensitivityLabel resource accepts the following input properties:

ColumnName
This property is required.
Changes to this property will trigger replacement.
string
The name of the column.
DatabaseName
This property is required.
Changes to this property will trigger replacement.
string
The name of the database.
ManagedInstanceName
This property is required.
Changes to this property will trigger replacement.
string
The name of the managed instance.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
SchemaName
This property is required.
Changes to this property will trigger replacement.
string
The name of the schema.
TableName
This property is required.
Changes to this property will trigger replacement.
string
The name of the table.
ClientClassificationSource string | Pulumi.AzureNative.Sql.ClientClassificationSource
InformationType string
The information type.
InformationTypeId string
The information type ID.
LabelId string
The label ID.
LabelName string
The label name.
Rank Pulumi.AzureNative.Sql.SensitivityLabelRank
SensitivityLabelSource Changes to this property will trigger replacement. string
The source of the sensitivity label.
ColumnName
This property is required.
Changes to this property will trigger replacement.
string
The name of the column.
DatabaseName
This property is required.
Changes to this property will trigger replacement.
string
The name of the database.
ManagedInstanceName
This property is required.
Changes to this property will trigger replacement.
string
The name of the managed instance.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
SchemaName
This property is required.
Changes to this property will trigger replacement.
string
The name of the schema.
TableName
This property is required.
Changes to this property will trigger replacement.
string
The name of the table.
ClientClassificationSource string | ClientClassificationSource
InformationType string
The information type.
InformationTypeId string
The information type ID.
LabelId string
The label ID.
LabelName string
The label name.
Rank SensitivityLabelRank
SensitivityLabelSource Changes to this property will trigger replacement. string
The source of the sensitivity label.
columnName
This property is required.
Changes to this property will trigger replacement.
String
The name of the column.
databaseName
This property is required.
Changes to this property will trigger replacement.
String
The name of the database.
managedInstanceName
This property is required.
Changes to this property will trigger replacement.
String
The name of the managed instance.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
schemaName
This property is required.
Changes to this property will trigger replacement.
String
The name of the schema.
tableName
This property is required.
Changes to this property will trigger replacement.
String
The name of the table.
clientClassificationSource String | ClientClassificationSource
informationType String
The information type.
informationTypeId String
The information type ID.
labelId String
The label ID.
labelName String
The label name.
rank SensitivityLabelRank
sensitivityLabelSource Changes to this property will trigger replacement. String
The source of the sensitivity label.
columnName
This property is required.
Changes to this property will trigger replacement.
string
The name of the column.
databaseName
This property is required.
Changes to this property will trigger replacement.
string
The name of the database.
managedInstanceName
This property is required.
Changes to this property will trigger replacement.
string
The name of the managed instance.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
schemaName
This property is required.
Changes to this property will trigger replacement.
string
The name of the schema.
tableName
This property is required.
Changes to this property will trigger replacement.
string
The name of the table.
clientClassificationSource string | ClientClassificationSource
informationType string
The information type.
informationTypeId string
The information type ID.
labelId string
The label ID.
labelName string
The label name.
rank SensitivityLabelRank
sensitivityLabelSource Changes to this property will trigger replacement. string
The source of the sensitivity label.
column_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the column.
database_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the database.
managed_instance_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the managed instance.
resource_group_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
schema_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the schema.
table_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the table.
client_classification_source str | ClientClassificationSource
information_type str
The information type.
information_type_id str
The information type ID.
label_id str
The label ID.
label_name str
The label name.
rank SensitivityLabelRank
sensitivity_label_source Changes to this property will trigger replacement. str
The source of the sensitivity label.
columnName
This property is required.
Changes to this property will trigger replacement.
String
The name of the column.
databaseName
This property is required.
Changes to this property will trigger replacement.
String
The name of the database.
managedInstanceName
This property is required.
Changes to this property will trigger replacement.
String
The name of the managed instance.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
schemaName
This property is required.
Changes to this property will trigger replacement.
String
The name of the schema.
tableName
This property is required.
Changes to this property will trigger replacement.
String
The name of the table.
clientClassificationSource String | "None" | "Native" | "Recommended" | "MIP"
informationType String
The information type.
informationTypeId String
The information type ID.
labelId String
The label ID.
labelName String
The label name.
rank "None" | "Low" | "Medium" | "High" | "Critical"
sensitivityLabelSource Changes to this property will trigger replacement. String
The source of the sensitivity label.

Outputs

All input properties are implicitly available as output properties. Additionally, the ManagedDatabaseSensitivityLabel resource produces the following output properties:

AzureApiVersion string
The Azure API version of the resource.
Id string
The provider-assigned unique ID for this managed resource.
IsDisabled bool
Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.
ManagedBy string
Resource that manages the sensitivity label.
Name string
Resource name.
Type string
Resource type.
AzureApiVersion string
The Azure API version of the resource.
Id string
The provider-assigned unique ID for this managed resource.
IsDisabled bool
Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.
ManagedBy string
Resource that manages the sensitivity label.
Name string
Resource name.
Type string
Resource type.
azureApiVersion String
The Azure API version of the resource.
id String
The provider-assigned unique ID for this managed resource.
isDisabled Boolean
Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.
managedBy String
Resource that manages the sensitivity label.
name String
Resource name.
type String
Resource type.
azureApiVersion string
The Azure API version of the resource.
id string
The provider-assigned unique ID for this managed resource.
isDisabled boolean
Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.
managedBy string
Resource that manages the sensitivity label.
name string
Resource name.
type string
Resource type.
azure_api_version str
The Azure API version of the resource.
id str
The provider-assigned unique ID for this managed resource.
is_disabled bool
Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.
managed_by str
Resource that manages the sensitivity label.
name str
Resource name.
type str
Resource type.
azureApiVersion String
The Azure API version of the resource.
id String
The provider-assigned unique ID for this managed resource.
isDisabled Boolean
Is sensitivity recommendation disabled. Applicable for recommended sensitivity label only. Specifies whether the sensitivity recommendation on this column is disabled (dismissed) or not.
managedBy String
Resource that manages the sensitivity label.
name String
Resource name.
type String
Resource type.

Supporting Types

ClientClassificationSource
, ClientClassificationSourceArgs

None
None
Native
Native
Recommended
Recommended
MIP
MIP
ClientClassificationSourceNone
None
ClientClassificationSourceNative
Native
ClientClassificationSourceRecommended
Recommended
ClientClassificationSourceMIP
MIP
None
None
Native
Native
Recommended
Recommended
MIP
MIP
None
None
Native
Native
Recommended
Recommended
MIP
MIP
NONE
None
NATIVE
Native
RECOMMENDED
Recommended
MIP
MIP
"None"
None
"Native"
Native
"Recommended"
Recommended
"MIP"
MIP

SensitivityLabelRank
, SensitivityLabelRankArgs

None
None
Low
Low
Medium
Medium
High
High
Critical
Critical
SensitivityLabelRankNone
None
SensitivityLabelRankLow
Low
SensitivityLabelRankMedium
Medium
SensitivityLabelRankHigh
High
SensitivityLabelRankCritical
Critical
None
None
Low
Low
Medium
Medium
High
High
Critical
Critical
None
None
Low
Low
Medium
Medium
High
High
Critical
Critical
NONE
None
LOW
Low
MEDIUM
Medium
HIGH
High
CRITICAL
Critical
"None"
None
"Low"
Low
"Medium"
Medium
"High"
High
"Critical"
Critical

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:sql:ManagedDatabaseSensitivityLabel current /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource} 
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Azure Native pulumi/pulumi-azure-native
License
Apache-2.0