Det lykkedes mig at identificere svaret. Til My-SQL
for at dekryptere:
SELECT CAST(AES_DECRYPT(encrypted-field,'my-encryption-key') as CHAR(50)) from table
for at kryptere:
SELECT AES_ENCRYPT(encrypted-field,'my-encryption-key') from table;
For H2:
krypter:
ENCRYPT('AES', STRINGTOUTF8('<encryption-key>'), STRINGTOUTF8('<text to be encrypted>'))
dekryptere:
TRIM(CHAR(0) FROM UTF8TOSTRING(DECRYPT('AES', STRINGTOUTF8('<encryption-key>'), '<text to be encrypted>')))