SQL 2016 - Column Encryption - WCF error - Microsoft Community


hi ,

we have sql 2016 version of sql installed .

we trying enable column level encryption on of columns .

we receiving following error when use wcf service interact db .

 

system.data.sqlclient.sqlexception (0x80131904): operand type clash: nvarchar incompatible nvarchar(80) encrypted (encryption_type = 'deterministic', encryption_algorithm_name = 'aead_aes_256_cbc_hmac_sha_256', column_encryption_key_name = 'cek12', column_encryption_key_database_name = 'fatca_dw8_standard')

incorrect parameter encryption metadata received client. error occurred during invocation of batch , therefore client can refresh parameter encryption metadata calling sp_describe_parameter_encryption , retry.

   @ system.data.sqlclient.sqlconnection.onerror(sqlexception exception, boolean breakconnection, action`1 wrapcloseinaction)

   @ system.data.sqlclient.sqlinternalconnection.onerror(sqlexception exception, boolean breakconnection, action`1 wrapcloseinaction)

   @ system.data.sqlclient.tdsparser.throwexceptionandwarning(tdsparserstateobject stateobj, boolean callerhasconnectionlock, boolean asyncclose)

   @ system.data.sqlclient.tdsparser.tryrun(runbehavior runbehavior, sqlcommand cmdhandler, sqldatareader datastream, bulkcopysimpleresultset bulkcopyhandler, tdsparserstateobject stateobj, boolean& dataready)

   @ system.data.sqlclient.sqlcommand.finishexecutereader(sqldatareader ds, runbehavior runbehavior, string resetoptionsstring)

   @ system.data.sqlclient.sqlcommand.runexecutereadertds(commandbehavior cmdbehavior, runbehavior runbehavior, boolean returnstream, boolean async, int32 timeout, task& task, boolean asyncwrite, sqldatareader ds, boolean describeparameterencryptionrequest)

   @ system.data.sqlclient.sqlcommand.runexecutereadertdswithtransparentparameterencryption(commandbehavior cmdbehavior, runbehavior runbehavior, boolean returnstream, boolean async, int32 timeout, task& task, boolean asyncwrite, sqldatareader ds, boolean describeparameterencryptionrequest, task describeparameterencryptiontask)

   @ system.data.sqlclient.sqlcommand.runexecutereader(commandbehavior cmdbehavior, runbehavior runbehavior, boolean returnstream, string method, taskcompletionsource`1 completion, int32 timeout, task& task, boolean asyncwrite)

   @ system.data.sqlclient.sqlcommand.internalexecutenonquery(taskcompletionsource`1 completion, string methodname, boolean sendtopipe, int32 timeout, boolean asyncwrite)

   @ system.data.sqlclient.sqlcommand.executenonquery()

   @ microsoft.practices.enterpriselibrary.data.database.doexecutenonquery(dbcommand command)

   @ microsoft.practices.enterpriselibrary.data.database.executenonquery(dbcommand command)

   @ cti.ew8.accountsprocess.dataaccess.repository`1.add(iaddfactory`1 addfactory, tlistobject domainobj, string identitycol)

clientconnectionid:aa0dbed1-6e9a-43ea-92a4-b31627b85249

 

connection string :

ata source=serverip;initial catalog=ic;uid=sa;pwd=thisiswin@k;connect timeout=200;current language=us_english;encrypt=true;trustservercertificate=true;column encryption setting=enabled;

 

we using enterprise library calling stored procedure .

 

the same code works when invoke stored procedure aspx page . there setting needs done in webservice make work ?



Community Participation Center / News and Announcements



Comments

Popular posts from this blog

Getting ErrorCode: 120018 when trying to access Microsoft account - Microsoft Community

The message was sent to a distribution list ‎(DL)‎ - Microsoft Community

What is the Office 365 default group Mailbox Users ISV Access Enabled - Microsoft Community