SqlCommandColumnEncryptionSetting SqlCommandColumnEncryptionSetting SqlCommandColumnEncryptionSetting SqlCommandColumnEncryptionSetting Enum

定义

指定读取和写入加密列时将如何发送及接收数据。 根据特定的查询,正当使用非加密列时跳过 Always Encrypted 驱动程序的处理可能会降低性能影响。 请注意这些设置不能用于绕过加密以及获取纯文本数据的访问权限。 有关详细信息,请参阅 Always Encrypted(数据库引擎)For details, see Always Encrypted (Database Engine).

public enum class SqlCommandColumnEncryptionSetting
public enum SqlCommandColumnEncryptionSetting
type SqlCommandColumnEncryptionSetting = 
Public Enum SqlCommandColumnEncryptionSetting
继承
SqlCommandColumnEncryptionSettingSqlCommandColumnEncryptionSettingSqlCommandColumnEncryptionSettingSqlCommandColumnEncryptionSetting

字段

Disabled Disabled Disabled Disabled 3

对查询禁用 Always Encrypted。Disables Always Encrypted for the query.

Enabled Enabled Enabled Enabled 1

为查询启用 Always Encrypted。Enables Always Encrypted for the query.

ResultSetOnly ResultSetOnly ResultSetOnly ResultSetOnly 2

指定驱动程序中 Always Encrypted 例程应只能处理命令的结果。Specifies that only the results of the command should be processed by the Always Encrypted routine in the driver. 当命令不具有需要加密的任何参数时使用此值。Use this value when the command has no parameters that require encryption.

UseConnectionSetting UseConnectionSetting UseConnectionSetting UseConnectionSetting 0

指定该命令应默认为连接字符串中的 Always Encrypted 设置。Specifies that the command should default to the Always Encrypted setting in the connection string.

注解

  • 如果为查询禁用了 Always Encrypted, 并且该查询具有需要加密的参数 (对应于加密列的参数), 则查询将失败。If Always Encrypted is disabled for a query and the query has parameters that need to be encrypted (parameters that correspond to encrypted columns), the query will fail.

  • 如果为查询禁用了 Always Encrypted, 并且查询从加密列返回结果, 则查询将返回加密值。If Always Encrypted is disabled for a query and the query returns results from encrypted columns, the query will return encrypted values. 加密值将具有 varbinary 数据类型。The encrypted values will have the varbinary datatype.

适用于

另请参阅