Encoding error when running script

Asked

Viewed 26 times

1

well, I’m trying to run the script this way:

psql -U [usuario] -d [banco] -f [script]

and in the cmd appears like this:

DROP TABLE
CREATE TABLE
COMMENT
COMMENT
psql:pais.sql:282: ERROR:  character with byte sequence 0x81 in encoding "WIN1252" has no equivalent in encoding "UTF8"

in my research about what this error might be, I found these commands:

SET client_encoding TO 'UTF8';

Only this command is running when I’m already inside the psql, and it works. but to run the script (as far as my knowledge and what my research showed) I can only run it outside psql. and off psql the same encoding error.

has some change I can make in my sql file for it to run as needed?

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.