14

I recently installed PostgreSql and I am trying to create a new database. Unfortunetly I got and error while creating the database:

"'utf8' codec can't decode byte 0xe9 in position 42: invalid continuation byte" enter image description here

What is the problem exactly thank you

Laurenz Albe
  • 209,280
  • 17
  • 206
  • 263
narcisse
  • 401
  • 4
  • 8
  • 15
  • 2
    It is not a PostgreSQL problem, but a pgAdmin problem. Perhaps there is a database name or a configuration parameter with a value containing "é" and pgAdmin is choking on it. – Laurenz Albe Aug 27 '17 at 05:12
  • 1
    Seems like you should report a PgADmin bug – Craig Ringer Aug 27 '17 at 14:11
  • what is the version of your pgAdmin4 and your windows10 system locale, and also can you provide all the input values you gave in the dialog to re-produce the issue? – Murtuza Z Aug 31 '17 at 12:19

4 Answers4

4

Try to add the following line at the end of the pg_hba.conf file and then restart the PostgreSQL service:

host    all             all             all                 md5
Jean-François Corbett
  • 37,420
  • 30
  • 139
  • 188
zesage
  • 49
  • 2
  • Can you explain what this is supposed to do? Perhaps restarting the server alone is the main solution. Why add an entry to the authentication file? – ADJenks Dec 30 '21 at 18:52
2

I had a similar error when upgrading from 4.5 to 4.7, the solution was to restart the pgAdmin server.

My error was: Error: 'utf-8' codec can't decode byte 0xe9 in position 0: invalid continuation byte

Walter D
  • 173
  • 2
  • 8
0

It's a conflict between local languages. PgAdmin is in English but maybe in the conf file the lc_messages variable is French, Spanish or something else. Try this

lc_messages = 'en_US'
Dotista
  • 404
  • 3
  • 12
0

I tried all the solutions above. None worked.

The solution for me was to install US ENGLISH as my language on my windows 10. Then I did the installation all over again in that language.

It's working now, and I do not have use US ENGLISH as my windows language xD

Sindre
  • 75
  • 1
  • 6