public static decodeBytea(raw as String) as Byte[]
Decodes PostgreSQL bytea text in hex or legacy escaped-octal format.
| Parameter | Description |
|---|---|
raw | Server text, or null for SQL NULL. |
Exact binary bytes; empty bytea is distinct from null.
bytes = PostgreSQLSupport.decodeBytea("\\x0041ff")
assert bytes[0] == Byte(0) and bytes[2] == Byte(255)