On 28 February 2012 20:25, rubix Rubix <[email protected]> wrote:
> Ok,
>
> I dropped the schema blog, I change the pwd and I change the adapter
> like this:
> development:
>  adapter: mysql2
>  encoding: utf8
>  database: blog_dev
>  pool: 5
>  username: root
>  password:
>  socket: /tmp/mysql.sock
>
>
> I execute rake db:create and I get the following error stack:
>
> ** Invoke db:create (first_time)
> ** Invoke db:load_config (first_time)
> ** Invoke rails_env (first_time)
> ** Execute rails_env
> ** Execute db:load_config
> ** Execute db:create
> rake aborted!
> uninitialized constant Mysql2
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/activerecord-3.1.3/lib/active_record/railtie
> s/databases.rake:81:in `rescue in create_database'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/activerecord-3.1.3/lib/active_record/railtie
> s/databases.rake:54:in `create_database'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/activerecord-3.1.3/lib/active_record/railtie
> s/databases.rake:42:in `block (2 levels) in <top (required)>'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:205:in
> `call'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:205:in
> `block
> in execute'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:200:in
> `each'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:200:in
> `execut
> e'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:158:in
> `block
> in invoke_with_call_chain'
> C:/Ruby192/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:151:in
> `invoke
> _with_call_chain'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:144:in
> `invoke
> '
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:116:in`invoke_task'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:94:in
> `block (2 levels) in top_level'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:94:in
> `each'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:94:in
> `block in top_level'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:133:in`standard_exception_handling'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:88:in
> `top_level'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:66:in
> `block in run'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:133:in`standard_exception_handling'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-.9.2.2/lib/rake/application.rb:63:in
> `run'
> C:/Ruby192/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/bin/rake:33:in `<top
> (required)>'
> C:/Ruby192/bin/rake:19:in `load'
> C:/Ruby192/bin/rake:19:in `<main>'
> Tasks: TOP => db:create
>
> Is it a missing gem?

Have you got
gem 'mysql2'
in Gemfile, and have you run bundle install?

If you think you have then do it again anyway, check whether it still
fails, and post the output from bundle install and post Gemfile.

Colin

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to