• Before continuing, please let me thank you for your help so far.

    After your previous posting I went ahead and tried the following in the new server:

    DECLARE @plaintext nvarchar(2000), @cyphertext nvarchar(2000)

    SET @plaintext = N'AAA'

    SET @cyphertext = EncryptByCert(Cert_ID('MyCert'), @plaintext)

    PRINT @cyphertext

    SELECT CAST(DecryptByCert(Cert_ID('MyCert'), @cyphertext) AS NVARCHAR)

    This works in the original server but in the one where I restored the database instead of getting AAA at the end of the above code I get NULL. So it appears that the certificate can be used to encrypt but not to decrypt. However, when I run the same code in the original server, I get AAA at the end.

    I hope this answers your question.