I'm working with PL/pgSQL and Orafce after a conversion from Oracle. In a function I'm writing in a file. I would like to write with the LATIN1 encoding. My database is in UTF8.
There is convert
functions but I think I miss something because I don't seems to find my use case.
convert('testé', 'UTF8', 'LATIN1') ==> in BYTEA test\351
The problem is that this function returns bytea
. How could I get a text
?