Configuring MySQL with Rails 3 (railsinstaller)

I am on Windows 7 and trying to use MySQL with Rails 3, I am beginner and just reading Rails tutorials, there is this configuration given:

adapter: mysql2
encoding: utf8
database: blog_development
pool: 5
username: root
socket: /tmp/mysql.sock

I have MySQL installed in Xampp, so where can I mention that it can access MySQL with localhost, what changes will be required, so that I can use that MySQL with Rails 3 app?


mysql2 gem installation is similar to mysql gem installation. Please see the following blog post which contains installation instructions for mysql gem:

You can ignore the MySQL installation instructions. You will need MySQL Connector/C download and then copy libmysql.dll from it to your Ruby installation (RailsInstaller one).

Hope that helps.

Source: stackoverflow
The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .