0

In terms of software development course I had to set up PostgreSQL on my laptop (Windows 11 x64). At pgAdmin on server creation (register) stage I reveived unreadable error message. I only managed myself is server name, host name, and password. Also if I change the username to some other it will placed instead of "postgres". Changing of pgAdmin interface language didn't helped. All the references are below

Also remind you that after I downloaded PostgreSQL (or pgAdmin) there is preset "PostgreSQL 16" server that has hostname=localhost and port=5432. If this server prevents me from creating a new one (with current settings), what do I need to change in the settings of the new server?

enter image description here enter image description here enter image description here

9
  • 1
    The implication here is that you do NOT have a Postgres server running on your machine. Remember that pgAdmin does not automatically install a server. That's completely separate. Does your machine default to a language other than English? Commented Jul 2, 2024 at 18:22
  • Looks like you installed pgAdmin, not PostgreSQL. pgAdmin is just one of many SQL clients that can be used to connect to PostgreSQL. Commented Jul 2, 2024 at 18:25
  • @TimRoberts, Thanks, I'll keep that in mind. At the moment, I have russian language on my machine Commented Jul 2, 2024 at 18:27
  • @FrankHeikens, Thanks for your respond. I managed to go this way: Google search "download PostgreSQL" -> PostgreSQL official website -> Download -> Windows -> "Download the installer certified by EDB for all supported PostgreSQL versions." -> PostgreSQL version 16.3 Windows x86-64. Did I missed something? Commented Jul 2, 2024 at 18:30
  • Did you initialize the server and did you start the server? I'm not familiar with Windows, don't know how to check this, but there must some proces running that says "postgres" Commented Jul 2, 2024 at 18:40

1 Answer 1

0

Firstly, the exception transcription says (possibly): "Unable to connect to server: connection failed::1), port 5432 failed: FATAL: password authentification failed for user 'postgres'"

Given transctiption lost the after-username part of message, but it fits most from my point-of-view because fixing this error fixed my own error

Solution: use the account password that is mentioned in the "username" line. If it is "postgres" (a.k.a. superuser), use password for superuser account. If it's some "other account" (e.g. "anothername" on second picture), use the password from "other account"


Secondly, it possible to fix symbols encoding by changing machine language or using SQL Shell (psql). If the SQL Shell has broken encoding do next:

  1. Open regedit
  2. Go to \HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Command Processor
  3. Create string parameter "Autorun"
  4. Put in it value "chcp some digits" (in my case "chcp 1251")

That might possibly help with the SQL Shell encoding situation

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.