PostgreSQL 9.4 数据库不能用 pgAdmin 3 (Windows 8.1) 保存

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/28881864/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-21 01:48:29  来源:igfitidea点击:

PostgreSQL 9.4 database cannot be saved with pgAdmin 3 (Windows 8.1)

postgresqlpgadmin

提问by len

I am working with confuence under Windows 8.1 and have produced a lot of Input there.

我在 Windows 8.1 下使用 confuence 并在那里产生了很多输入。

Now I wanted to backup my PostgreSQL 9.4 database with pgAdmin 3.

现在我想用 pgAdmin 3 备份我的 PostgreSQL 9.4 数据库

I get the error:

我收到错误:

C:\Program Files (x86)\pgAdmin III\1.18\pg_dump.exe --host localhost --port 5432 --username "postgres" --no-password --format custom --blobs --verbose --file "C:\Users\milenko\Desktop\output.backup" "confluence"

C:\Program Files (x86)\pgAdmin III\1.18\pg_dump.exe --host localhost --port 5432 --username "postgres" --no-password --format custom --blobs --verbose --file " C:\Users\milenko\Desktop\output.backup" "confluence"

pg_dump: server version: 9.4.1; pg_dump version: 9.3.1

pg_dump:服务器版本:9.4.1;pg_dump 版本:9.3.1

pg_dump: aborting because of server version mismatch

pg_dump:由于服务器版本不匹配而中止

Do you know a solution?

你知道解决办法吗?

回答by a_horse_with_no_name

You need to tell pgAdmin to use the 9.4 binaries, through the "Binary paths" section in the options dialog:

您需要通过选项对话框中的“二进制路径”部分告诉 pgAdmin 使用 9.4 二进制文件:

https://www.pgadmin.org/docs/pgadmin3/1.22.2/options-browser.html

https://www.pgadmin.org/docs/pgadmin3/1.22.2/options-browser.html



your pgAdmin version is a bit old as well. 1.20 ships with Postgres 9.4, not 1.18

您的 pgAdmin 版本也有点旧。1.20 附带 Postgres 9.4,而不是 1.18

回答by eXPRESS

Also I found very effective to just replace pg_dump.exe in pgadmin version folder with my pg_dump.exe from my Postgres database.

此外,我发现将 pgadmin 版本文件夹中的 pg_dump.exe 替换为 Postgres 数据库中的 pg_dump.exe 非常有效。

I see why the solution above is better, but if someone would have problems with that, this also seems like functional alternative.

我明白为什么上面的解决方案更好,但如果有人对此有问题,这似乎也是功能性的替代方案。

回答by Ricaom Sepol

This solution above works fine for me!. You should try. Inside pgadmin folder, change pg_dump.exe name to pg_dump-bkp.exe and copy&paste pg_dump.exe from postgres folder.

上面的这个解决方案对我来说很好用!你应该试试。在 pgadmin 文件夹中,将 pg_dump.exe 名称更改为 pg_dump-bkp.exe 并从 postgres 文件夹中复制并粘贴 pg_dump.exe。