【发布时间】:2016-12-05 14:32:22
【问题描述】:
我已加密表中的一列 mob_no。 加密列后,存储过程出错。
我在下面添加了sp
create procedure get_cut
@mobNo varchar(50),
@custId int
As
Begin
if(@mobNo = null or @mobNo = '')
Begin
select @mobNo = mob_no
from table1 where cust_id = @custId
End
select cust_name from tbl_cust where mob_no = @mobNo and cust_id = @custId
End
运行此 sp 时出现以下错误
消息 33299, 列/变量“@mobNo”的加密方案不匹配。 列/变量的加密方案是 (encryption_type = 'PLAINTEXT') '9' 行附近的表达式期望它是 (encryption_type = 'DETERMINISTIC', 加密算法名称 = 'AEAD_AES_256_CBC_HMAC_SHA_256', column_encryption_key_name = 'xxxx',column_encryption_key_database_name = 'mydb') (或更弱)。
【问题讨论】:
标签: sql-server stored-procedures always-encrypted