【问题标题】:How to encrypt column SQL Server 2016 Always Encrypted ? -Alter Query如何加密列 SQL Server 2016 Always Encrypted ? -更改查询
【发布时间】:2016-11-14 05:09:05
【问题描述】:

在 SQL Server 2016 中使用“始终加密”的查询很容易加密列。但是我们有现有的表。那么如何加密现有表中的列呢?我需要它使用改变查询。

我尝试了以下查询

alter table testemp alter column ename  add ENCRYPTED WITH (
ENCRYPTION_TYPE = DETERMINISTIC,
ALGORITHM = 'AEAD_AES_256_CBC_HMAC_SHA_256',
COLUMN_ENCRYPTION_KEY = CEK_Auto8) 

【问题讨论】:

    标签: sql sql-server-2016 always-encrypted


    【解决方案1】:

    Configuring Always Encrypted 段落中查看这篇文章 How to configure Always Encrypted in SQL Server 2016 using SSMS, PowerShell and T-SQL,它指出

    在现有数据库列上定义列加密

    可以通过Sql server management studioPowerShell 完成,但不能 使用T-SQL

    【讨论】:

      【解决方案2】:

      您可以使用 Sql server management studio 加密现有表中的列。

      请查看此MSDN page

      【讨论】:

      • 你能澄清一下这是否是唯一的方法吗?不能通过 T-SQL 或 .Net 数据提供程序完成吗?
      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多