skip to Main Content

I installed PostgreSQL and pgAdmin 4 on windows 10. Everything works in pgAdmin, but when i try to use psql i get this error:

enter image description here

After running ‘help’, i can not run any option such as ? or q. If i do, i get this error:

‘more’ is not recognized as internal or external command, operable program or batch file.

I found the chcp file in my WindowsSystem32. I assume it is the path that this file should be in. Also, i added C:Program FilesPostgreSQL14bin to my environmental variable and C:Program FilesPostgreSQL14lib to my system variable in PTAH. I restarted the windows expecting it to work, but it does not. Any idea what i should do here?

Thanks

3

Answers


  1. Chosen as BEST ANSWER

    I found the answer. I just copied the 'chcp', 'find' and 'more' files' from Windows/System32 and pasted them in C:Users and now everything is working.


  2. I’ll try to guess, you need to run chcp on the command line, and then run psql

    chcp 1252
    psql 
    
    Login or Signup to reply.
  3. I had the exact same problem. What worked for me was adding Windows/System32 to my PATH. That should give access to chcp (as well as a bunch more commands you will need for PSQL command line). This also would explain why you can’t run chcp from the command line and why moving the "chcp" and "more" files to "Users" would fix the issue (I’m guessing your users folder is somewhere in your PATH)

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search