This content has been marked as final. Show 3 replies
Try specifying the charset when you convert the strings back into byte.
As to which charset ... probably the default platform charset at the time the strings were created.
Hi EJP, thanks for your response.
The oracle charset is AL32UTF8; and have tried utf-8, ISO-8859-1 which doesn't work.
In java, can't find AL32UTF8, which seems to anyway be a subset of UTF-8.
You need to try to find out what characterset was originally used to create the strings, this was either specified explicitly in the code, or done with the default Java encoding for your platform. Unfortunately there still is potential for loss of information which might prevent you from correctly decrypting the string (eg, bytes not in the characterset might have been converted to a questionmark, ASCII controlcodes might have been converted to something safer by your database, etc).