Failure with DECRYPT_CHAR

Version 11.50.FC7, HP-UX 11.31 ia64

I have run into a strange problem. I have two databases in the same
instance. I encrypt a column with ENCRYPT_AES in one of these and
decrypt it using DECRYPT_CHAR, no problem at all.

In the exact same table in the other database I do the ENCRYPT_AES,
this works OK, but when I try to decrypt I get

-26012 The internal base64 decoding function failed.

The internal crypto library base64 decoding API failed.
it may be caused by a corrupted data.

I have so far failed to understand this, I use the same SP to do the
encryption and the same to do the decryption, any idea to why I get
this error in the second database. The data that I encrypt is the