Created
January 16, 2015 04:33
-
-
Save mberman84/4869b030d931f3baf62b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class AddCreatedAtIndexOnMessage < ActiveRecord::Migration | |
| def up | |
| execute "CREATE INDEX index_messages_on_day ON messages USING btree (DATE(created_at AT TIME ZONE '-08:00'));" | |
| end | |
| def down | |
| execute "DROP INDEX index_messages_on_day;" | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment