Difference :: Main difference between the updown method and change method of the migration
If change does both, why bother with up and down? In some cases, your migration may require manual changes outside of Rails conventions that change does not support and can’t automatically figure the inverse of. For example, to manage some of our tables, we have implemented a “soft delete” service
change method does not support some of the rails conventions for example soft delete, so up down method of migration will never fail, change method can fail in some cases.
Comments
Post a Comment