MySQL Forums
Forum List  »  Newbie

Using AES_DECRYPT displays NULL
Posted by: Peter Kaye
Date: July 29, 2014 02:11AM

SELECT CAST(AES_DECRYPT(AES_ENCRYPT('x','y'), 'y') AS CHAR);

correctly displays x

SELECT AES_ENCRYPT( 'x', 'y' )

displays e570ca3c339299069727ba6d33fec255

SELECT CAST(AES_DECRYPT('e570ca3c339299069727ba6d33fec255', 'y') AS CHAR);

where the encrypted value is included instead of the encrypt statement

displays NULL

What am I going wrong ? Thanks.

Options: ReplyQuote


Subject
Written By
Posted
Using AES_DECRYPT displays NULL
July 29, 2014 02:11AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.