BASE64_DECODE v13
Use the BASE64_DECODE
function to translate a Base64 encoded string to the original value originally encoded by BASE64_ENCODE
. The signature is:
This function returns a RAW
value.
Parameters
r
r
is the string that contains the Base64 encoded data that will be translated to RAW
form.
Examples
Before executing the following example, invoke the command:
This command instructs the server to escape any non-printable characters, and to display BYTEA
or RAW
values onscreen in readable form. For more information, refer to the Postgres Core Documentation available at:
https://www.postgresql.org/docs/current/static/datatype-binary.html
The following example first encodes (using BASE64_ENCODE
), and then decodes (using BASE64_DECODE
) a string that contains the text abc: