encode()

A function converting bytea data into text formats

encode() is a system function for converting bytea data into specific text formats.

encode() was added in PostgreSQL 7.2.

Usage

encode ( bytes bytea, format text ) → text

format can be one of the following values:

  • base64
  • escape
  • hex

Change history

Categories

String manipulation, System function

See also

decode()