"Some transformations are destructive in a manner that cannot be reversed. Migrations of that kind should raise an ActiveRecord::IrreversibleMigration exception in their down method."
But there is way you can reverse it????
you can reverse it by using "Reversible" , basically this method allow you to specify up and down behavior for part of the migration. so in Reversible part you can write your your own method
thanks for your comment , stay tuned for more interesting topic . if you want something that i cover on my ruby on rails blog then please do let me know . _^
Some comments have been hidden by the post's author - find out more
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
in api.rubyonrails.org/classes/Active... website written:-
"Some transformations are destructive in a manner that cannot be reversed. Migrations of that kind should raise an ActiveRecord::IrreversibleMigration exception in their down method."
But there is way you can reverse it????
you can reverse it by using "Reversible" , basically this method allow you to specify up and down behavior for part of the migration. so in Reversible part you can write your your own method
thanks for your comment , stay tuned for more interesting topic . if you want something that i cover on my ruby on rails blog then please do let me know . _^