First add these lines to database.yml
common: &common encoding: utf8 collation: utf8_general_ci development: <<: *common .... production: <<: *common
Changing database character set and collation
1. Log into phpMyAdmin.
2. Select your database from the list on the left.
3. Click on “Operations” from the top set of tabs.
4. In the Collation box, choose your new collation from the dropdown menu. utf8_general_ci is the most common utf8 collation.
5. Now rollback or down your specific migration.
6. Now rake db:migrate / rake db:migrate:up VERSION=’migration_version_number’ [RAILS_ENV=’production/development’]
7. Click on some table of your database
8. Click “Structure” tab and check collation column value