1. 安装 PostgreSQL 适配器驱动程序
详细步骤参见:http://glauche.de/2007/12/21/installing-native-postgres-gem-for-ruby/
运行 gem install ruby-postgres,在列表中选择对应的平台(mswin32)进行安装,如:
D:\source\Personal\lnj\tour>gem install ruby-postgres
Bulk updating Gem source index for: http://gems.rubyforge.org
Select which gem to install for your platform (i386-mswin32)
1. ruby-postgres 0.7.1.2006.04.06 (ruby)
2. ruby-postgres 0.7.1.2006.04.06 (mswin32)
3. ruby-postgres 0.7.1.2006.04.05 (mswin32)
4. ruby-postgres 0.7.1.2006.04.05 (ruby)
5. Skip this gem
6. Cancel installation
> 2
Successfully installed ruby-postgres-0.7.1.2006.04.06-mswin32
Installing ri documentation for ruby-postgres-0.7.1.2006.04.06-mswin32...
Installing RDoc documentation for ruby-postgres-0.7.1.2006.04.06-mswin32...
2. 测试驱动程序
在控制台中运行 irb,输入命令 require "postgres",如果返回 true,说明链接成功,如果出现错误:
* 报错:"没有找到 libpq.dll,因此这个应用程序未能启动",将 C:\Program Files\PostgreSQL\8.3\bin\libpq.dll 复制到 C:\ruby\bin。
* 报 错:"无法定位序数 284 于动态链接库 SSLEAY32.dll 上",可能是 ruby 所用 SSLEAY32.dll 的版本号低于 postgresql 使用的,将 C:\Program Files\PostgreSQL\8.3\bin\libeay32.dll 和 ssleay32.dll 替换 C:\ruby\bin 下同名文件。
* 报错:"没有找到 xxx.dll,因此这个应用程序未能启动",将 C:\Program Files\PostgreSQL\8.3\bin\xxx.dll 复制到 C:\ruby\bin。
* 可能需要复制下列文件:
o libeay32.dll 替换
o ssleay32.dll 替换
o libpq.dll
o libintl3.dll
o libiconv2.dll
o krb5_32.dll
o comerr32.dll
o k5sprt32.dll
o gssapi32.dll
分享到:
相关推荐
pgjdbc, PostgreSQL驱动程序驱动程序 驱动程序PostgreSQL驱动程序( 短 PgJDBC ) 允许Java程序使用标准的数据库独立Java代码连接到PostgreSQL数据库。 是用纯 Java ( 类型 4 ) 编写的开放源码JDBC驱动程序,并在...
windows下编译安装postgresql.docx windows下编译安装postgresql.docx windows下编译安装postgresql.docx
搜集了windows平台的postgreSQL的ODBC程序,官网上没有找到。注意64位系统安装32位ODBC程序后,请到C:\Windows\SysWOW64下面打开ODBC配置程序
DBeaver工具再连接数据库 postgresql 时需要的驱动 jar 包,7z 包里面有多个jar,解压后直接在DBeaver的菜单 数据库》驱动管理器》编辑驱动‘postgresql’ 面板添加该文件夹即可
postgresql-13.3-2-windows-x64 windows安装器 postgresql-13.3-2-windows-x64 windows安装器 postgresql-13.3-2-windows-x64 windows安装器 postgresql-13.3-2-windows-x64 windows安装器 postgresql-13.3-2-...
本文是postgreSQL 13.5 windows安装与 Linux 安装 及 常见命令, 由作者自身一步步实践写出来了,主要也是为了记录下操作步骤备忘. 全文通俗易懂,图文并茂一步步安装 和 并使用psql 常规命令; 本文是postgreSQL 13.5 ...
postgresql-42.6.0.jar 对 java 8的支持postgresql驱动包
Postgresql
Windows下安装PostgreSQL8.2图文并茂
Postgresql 10.20.2 Windows 64位安装包Postgresql 10.20.2 Windows 64位安装包Postgresql 10.20.2 Windows 64位安装包Postgresql 10.20.2 Windows 64位安装包Postgresql 10.20.2 Windows 64位安装包Postgresql ...
Qt 5.9.3 MySQL和PostgreSQL本地编译驱动,Qt自带的的MySQL和PostGreSQL驱动在程序出包后,报错:“Driver not loaded”,使用本地源码编译生成的驱动替换后即可正常连接数据库。
postgresql 9.4版本的驱动程序jar包
Qt 6.2.2 版本下编译的postgresql 14 驱动, 解压压缩包内的文件,拷贝到你的exe程序目录
适用于java1.6环境下连接postgresql数据库的驱动包分享
OLEDB驱动程序大全 PostgreSQL-OleDB-Provider
最新版本PostgreSQL JDBC驱动包,还包括老版本驱动包: postgresql-8.4-703.jdbc4(支持PostgreSQL 8) postgresql-9.4.1212(支持PostgreSQL 9) postgresql-42.2.10(支持PostgreSQL 42)
postgresql 安装程序。这是个开源的数据库管理程序。
postgresql 的jar驱动包 postgresql 的jar驱动包 postgresql 的jar驱动包
postgresql驱动程序有严重的连接性能问题,本代码可以解决
zhparser是Postgresql中进行中文分词的常用扩展,网上的相关资料很多,安装的教程也不少,但大多数是linux的,并没有windows的安装介绍。原因有两个方面,一个是本身像这种数据库服务器一般都是linux系统的,另外一...