-1

I am trying to encrypt a varchar (empcode) and a bigint column using SQL Server Management Studio, which are being referenced by multiple stored procedures and views. (using Always Encrypted on SQL Server 2016)

Its throwing me an Error SQL 71501 ->

(Object 1) has unresolved reference to (Object 2)

How can I overcome such problems?

Thanks

1 Answers1

0

Which version of SSMS, are you using? If it's older than 17.0, I recommend trying the newest version (https://learn.microsoft.com/en-us/sql/ssms/download-sql-server-management-studio-ssms).

Based on your description, I suspect you are using SSMS 16.x. The likely root cause of this problem is that your stored procedures has external dependencies (on objects in other databases) or has broken dependencies. in SSMS 16.x, the Always Encrypted wizard does a comprehensive validation of all dependencies in the entire database, including objects not dependent on that tables that you are trying to encrypt. We have fixed this problem in SSMS 17, by limiting the validation only to the tables containing the columns you are encrypting and the wizard does not error out anymore when encountering a validation error. Instead, it completes encryption and produces a warning, allowing you to investigate/address the issue later.

Thanks,

Jakub