-
-
Save hemanth22/9ef2a65480d3d64038f7b2d71ef2c890 to your computer and use it in GitHub Desktop.
[PL/SQL Base64 encode decode] #oracle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
declare | |
r raw(32767); | |
begin | |
r := utl_raw.cast_to_raw('Test'); | |
dbms_output.put_line(r); | |
r := utl_encode.base64_encode(r); | |
dbms_output.put_line(utl_raw.cast_to_varchar2(r)); | |
r := utl_encode.base64_decode(r); | |
dbms_output.put_line(utl_raw.cast_to_varchar2(r)); | |
end; | |
/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select utl_raw.cast_to_varchar2(utl_encode.base64_encode(utl_raw.cast_to_raw('Aladdin:open sesame'))) | |
from dual; | |
select utl_raw.cast_to_varchar2(utl_encode.base64_decode(utl_raw.cast_to_raw('QWxhZGRpbjpvcGVuIHNlc2FtZQ=='))) | |
from dual; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment