Open akshitjain opened 9 years ago
Waterline does have migration strategies (alter
, drop
, and safe
) that can be set per collection. The docs do need some info on that! @akshitjain do you mind if we rename this issue to "Add info on migration strategies to docs"?
In the meantime, @akshitjain, check-out http://sailsjs.org/#!/documentation/concepts/ORM/model-settings.html?q=migrate . Typically we say that only safe
is suited to a production environment, which means you would have to do migrations manually. There is some talk about adding a create
option, which would allow adapters to perform non-destructive migrations on their own, which might cater to a prod environment as well.
Addendum to what @devinivy said: even though create
is not documented it's already implemented and working. More details on balderdashy/waterline#846.
@devinivy issue title changed
Is there any function or we have to do it by going to the table definition and entering there.