I want to configure mysql instead of Sqlite3. I had already configured the database.yml file:
development:
adapter: mysql
database: test
username:false
password:neha
host :localhost
port:3306
and also installed the mysql gem using gem install mysql
still i stuck out in error...please help me out :\rails\TestApp1>ruby script/server
Booting WEBrick Rails 2.3.11 application starting on http://0.0.0.0:3000 :/Ruby192/lib/ruby/1.9.1/syck.rb:135:in
load': syntax error on line 13, col 0:test:' (ArgumentError) from C:/Ruby192/lib/ruby/1.9.1/syck.rb:135:inload' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/rails-2.3.11/lib/initializer.rb:926:indatabase_configuration' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/rails-2.3.11/lib/initializer.rb:437:ininitialize_database' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/rails-2.3.11/lib/initializer.rb:141:inprocess' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/rails-2.3.11/lib/initializer.rb:113:inrun' from C:/rails/TestApp1/config/environment.rb:9:in' from :29:inrequire' from <internal:lib/rubygems/custom_require>:29:inrequire' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-2.3.11/lib/active_support/dependencies.rb:182:inblock in require' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-2.3.11/lib/active_support/dependencies.rb:547:innew_constants_in' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-2.3.11/lib/active_support/dependencies.rb:182:inrequire' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/rails-2.3.11/lib/commands/server.rb:84:in' from :29:inrequire' from <internal:lib/rubygems/custom_require>:29:inrequire' from script/server:3:in `' i got this error
@d11wtq:
here is my yml file for mysql configuration:
ActiveRecord::Base.establish_connection(
:adapter => "mysql",
:host => "localhost",
:username => "root",
:password => "neha",
:database => "ruby"
)
& where i have to put
require 'mysql'