0
當我運行命令rake db:create
我得到以下信息:Rails的數據庫創建
Couldn't create database for {"password"=>"secret1", "username"=>"root", "host"=>"localhost", "database"=>"zooz_development", "encoding"=>"utf8", "port"=>3307,
"adapter"=>"mysql"}, charset: utf8, collation: utf8_unicode_ci (if you set the c
harset manually, make sure you have a matching collation)
我Win7上 MySQL是工作的端口上的工作3307 我已經安裝了MySQL的寶石 ,這是我的database.yml文件:
development:
adapter: mysql
encoding: utf8
database: zooz_development
username: root
password: secret1
port: 3307
host: localhost
# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# Do not set this db to the same as development or production.
test:
adapter: mysql
encoding: utf8
database: chmaysa_test
username: root
password: secret1
port: 3307
host: localhost
production:
adapter: mysql
encoding: utf8
database: zooz_development
username: root
password: secret1
port: 3307
host: localhost
適配器從
mysql
您可以連接使用上市特權的數據庫?你總是可以通過** rails db ** – 2013-03-27 18:58:29