-
-
Save thephw/10843b5ec89c7746fe8d to your computer and use it in GitHub Desktop.
Undesired Rails Schema Changed (Column moved etc.)
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
pg_dump --create --column-inserts melody_development > melody_development_dump.sql # or whatever your database is called | |
# edit dump.sql and change the column order | |
# stop webserver | |
be rake db:drop | |
be rake db:create | |
psql -f melody_development_dump.sql melody_development | |
be rake db:migrate | |
be rake db:test:prepare |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment