ENCRYPT_TDES

Returns a value that is the result of encrypting data-string using the Triple DES encryption algorithm. The password used for decryption is either the password-string value or the encryption password value (assigned by the SET ENCRYPTION PASSWORD statement).

Example

Assume that table EMP1 has a social security column called SSN. This example uses the ENCRYPTION PASSWORD value to hold the encryption password.

  SET ENCRYPTION PASSWORD = 'Ben123'

  INSERT INTO EMP1 (SSN) VALUES ENCRYPT_TDES( '289-46-8832' )