0
我正在使用Ruby on Rails(rails版本2.3.4),并在Windows上使用pg gem(版本0.12.2)。 我的database.yml文件有以下内容:Ruby on Rails错误:无效的连接“适配器”
production:
adapter: postgresql
encoding: utf8
host: localhost
database: canvas4
username: canvas
password: canvas
port: 5433
timeout: 5000
pool: 5
queue:
adapter: postgresql
encoding: utf8
database: canvas4_queue
host: localhost
port: 5433
username: canvas
password: canvas
timeout: 5000
pool: 5
但是当我运行命令:bundle exec rake db:initial_setup RAILS_ENV=production
,出现错误:
Invalid connection "adapter"
我也试图与gem "activerecord-postgresql-adapter"
但同样的错误如上所述。
我可以用sqlite3驱动程序成功安装。
你知道如何让postgresql适配器使用rails 2.3吗?