PostgreSQL 9 bytea type problems

January 19th 2011, 4:03 amCategory:Rails 5 comments

jga August 22nd 2011, 4:47 am

thank you, saved my butt :-D

Mahmood Dehghan October 9th 2011, 10:08 am

Thanks a lot. I've spent a few hours, wondering why the output of getBytes() is a hex string.
Really why is it that way? bytea data type is a byte array (byte[]). When we store byte[], we expect to get byte[].
I'm still wondering why the default output is a hex string.

Alexander June 26th 2012, 7:46 am

Thanks a lot! Your post has saved my application at production :)

adam February 5th 2013, 10:27 am

Whew, after migrating the DB I thought I had screwed up the backup/restore procedure. After about 5 retries it dawned on me to look at the output format and I found myself facing the problem you have described. Thanks for the solution!

Pablo October 2nd 2015, 8:26 pm

Thanks! It works!

Leave a Comment