windows XAMPP 与 PostgreSQL 9

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/6818041/
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-09-15 17:34:45  来源:igfitidea点击:

XAMPP with PostgreSQL 9

phpwindowsapachepostgresqlxampp

提问by Ahmad

I installed XAMPP 1.7.4(VC6) from this link:
http://www.apachefriends.org/download.php?xampp-win32-1.7.4-VC6-installer.exe

我从这个链接安装了 XAMPP 1.7.4(VC6):http: //www.apachefriends.org/download.php?xampp-win32-1.7.4-VC6-installer.exe

The XAMPP 1.7.4 contains:

XAMPP 1.7.4 包含:

  • Apache 2.2.17,
  • MySQL 5.5.8,
  • PHP 5.3.5
  • 阿帕奇 2.2.17,
  • MySQL 5.5.8,
  • PHP 5.3.5

Then, I installed PostgreSQL 9 (64bit).

然后,我安装了 PostgreSQL 9(64 位)。

It's very simple to enable PHP and PostgreSQL connection - just uncomment extension=php_pgsql.dlland extension=php_pdo_pgsql.dllin the php.inifile.

这是非常简单的,以使PHP和PostgreSQL连接-只是取消注释extension=php_pgsql.dllextension=php_pdo_pgsql.dllphp.ini文件。

But, I got an error when starting Apache:

但是,我在启动 Apache 时遇到错误:

enter image description hereenter image description here

在此处输入图片说明在此处输入图片说明

Can anybody help and explain?

有人可以帮忙解释一下吗?

回答by Awea

May be you can fix it with follow this instructions.

也许您可以按照此说明进行修复。

回答by Ronald D. Willis

If the above doesn't work, try copying the libpg.dll file from your PostgreSQL installation folder over to your apache/bin folder

如果上述方法不起作用,请尝试将 libpg.dll 文件从 PostgreSQL 安装文件夹复制到 apache/bin 文件夹

回答by Ernesto

I had the same problem. I just copied the lib*.dll files from pgsql/lib/ directory to the apache /bin directory. It worked fine.

我有同样的问题。我只是将 lib*.dll 文件从 pgsql/lib/ 目录复制到 apache /bin 目录。它工作得很好。

回答by Derry

Simply navigate to your Postgresql/psqlODBC/0900/binand copy all contents here to your xampp apache/bin directory, then restart Apache. This worked on my xampp 1.7.4.

只需导航到您的Postgresql/psqlODBC/0900/bin并将此处的所有内容复制到您的 xampp apache/bin 目录,然后重新启动 Apache。这适用于我的 xampp 1.7.4。