我无法将mysql连接到rails,我试图修改database.yml和gemfile,但没有任何效果。请帮忙。
Rails环境配置
git:
version: git version 1.7.6.msysgit.0
ruby:
bin: C:/RailsInstaller/Ruby1.9.2/bin/ruby.exe
version: ruby 1.9.2p290 (2011-07-09) [i386-mingw32]
rails:
bin: C:/RailsInstaller/Ruby1.9.2/bin/rails.bat
version: Rails 3.1.1
过程
C:\Sites>cd demo
C:\Sites\demo>rake db:migration
rake aborted!
Incorrect MySQL client library version! This gem was compiled for 6.0.0 but the
client library is 5.0.27.
(See full trace by running task with --tracing)
我已经安装了mysql 5.5
答案 0 :(得分:0)
答案 1 :(得分:0)
database yml
development:
adapter: mysql2
database: railsapp
encoding: utf8
username: root
password: 1234
pool: 5
timeout: 5000
test:
adapter: mysql2
database: railsapp
encoding: utf8
username: root
password: 1234
pool: 5
timeout: 5000
production:
adapter: mysql2
database: railsapp
encoding: utf8
username: root
password: 1234
pool: 5
timeout: 5000