0

The following

"C:\Program Files (x86)\pgAdmin III\1.14\pg_restore.exe" --host localhost --port 5432 --username "postgres" --password "postgres" --dbname "base_nationale" --verbose "E:\dump\ff_d01_2011.dump"

gives this error message:

pg_restore: too many command-line arguments (first is "--host"

why it doesn't fuctionne?

1 Answers1

2

You can't specify a value for --password. That switch only forces a password prompt and should actually never be needed.

Just remove the part --password "postgres". If a password is needed, pg_restore will automatically prompt you for it.

If you want to run that command without a password prompt, you need a .pgpass file or use the environment variable PGPASS

Details are in the manual:

Or this SO question: How do I specify a password to psql non-interactively?

Community
  • 1
  • 1