Remove-​Sql​Column​Encryption​Key​Value

Removes an encrypted value from an existing column encryption key object in the database.

Syntax

Remove-SqlColumnEncryptionKeyValue
      [-Name] <String>
      [-InputObject] <Database>
      -ColumnMasterKeyName <String>
      [-Script]
      [-InformationAction <ActionPreference>]
      [-InformationVariable <String>]
      [<CommonParameters>]
Remove-SqlColumnEncryptionKeyValue
      [-Name] <String>
      [[-Path] <String>]
      -ColumnMasterKeyName <String>
      [-Script]
      [-InformationAction <ActionPreference>]
      [-InformationVariable <String>]
      [<CommonParameters>]

Description

The Remove-SqlColumnEncryptionKeyValue cmdlet modifies a column encryption key object in the database, by removing an entry for an encrypted value produced using the specified column master key.

Examples

Example 1: Remove a column encryption key value

PS C:\> Remove-SqlColumnEncryptionKeyValue -Name "CEK1" -ColumnMasterKey "CMK1"

This command removes the column encryption key value encrypted with a column master key named CMK1 from the column encryption key database object named CEK1.

Required Parameters

-ColumnMasterKeyName

Specifies the name of the column master key that was used to produce the encrypted value that this cmdlet removes.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InputObject

Specifies the SQL database object for which this cmdlet runs the operation.

Type:Database
Position:2
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Name

Specifies the name of the column encryption key object that this cmdlet removes.

Type:String
Position:1
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-InformationAction

Specifies how this cmdlet responds to an information event.The acceptable values for this parameter are:- Continue

  • Ignore
  • Inquire
  • SilentlyContinue
  • Stop
  • Suspend
Type:ActionPreference
Aliases:infa
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InformationVariable

Specifies an information variable.

Type:String
Aliases:iv
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Path

Specifies the path of the SQL database for which this cmdlet runs the operation. If you do not specify a value for this parameter, this cmdlet uses the current working location.

Type:String
Position:2
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Script

Indicates that this cmdlet returns a Transact-SQL script that performs the task that this cmdlet performs.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False