I have the following stored procedure which work as expected when run it run it using the EXEC command below in SSMS.
the CustomerAlternateKey column in both the [dbo].[DimCustomer] and dbo.TargetTable tables are encrypted using Always Encrypted Deterministic encryption using the Azure Key Vault option.
create or alter procedure uspMoveToTarget @keyvalue nvarchar(15)
as
begin
insert into TargetTable(CustomerKey, CustomerAlternateKey)
select
CustomerKey,
CustomerAlternateKey
from [dbo].[DimCustomer]
where CustomerAlternateKey = @keyvalue
end
declare @variable nvarchar(15) = 'AW00011000'
exec uspMoveToTarget @variable -- works
I have created a ADO.Net connection in SSIS with the Column Encryption Setting = "Enabled". I have added an "Execute SQL Task" and referenced the ADO.Net connection i just mentioned and added the value above into a package variable.
When i run my SSIS package i get the following error:
Error: 0xC002F210 at Execute SQL Task, Execute SQL Task: Executing the query "uspMoveToTarget" failed with the following error: "Failed to decrypt a column encryption key. Invalid key store provider name: 'AZURE_KEY_VAULT'. A key store provider name must denote either a system key store provider or a registered custom key store provider. Valid system key store provider names are: 'MSSQL_CERTIFICATE_STORE', 'MSSQL_CNG_STORE', 'MSSQL_CSP_PROVIDER'. Valid (currently registered) custom key store provider names are: . Please verify key store provider information in column master key definitions in the database, and verify all custom key store providers used in your application are registered properly.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly. Task failed: Execute SQL Task
I am not sure where to go from here as everything works as expected in SSMS. Are the additional configurations i need to make in SSIS for this to work?
Thanks in advance