How can I print bytea data as a hexadecimal string in PostgreSQL / pgAdmin III? How can I print bytea data as a hexadecimal string in PostgreSQL / pgAdmin III? postgresql postgresql

How can I print bytea data as a hexadecimal string in PostgreSQL / pgAdmin III?


Based on this answer, I found my solution to be

SELECT encode(my_column::bytea, 'hex') FROM my_table;