Deploying custom modules that use ORM
When developing a module that requires multiple tables for storing data (as I understand this right now, none of the data is 'extending' the Document class) can we completely generate these database tables using the ORM?
In other words, does the ORM support migrations/schema changes?
Thanks!
PS. I'm new to Sitefinity and still evaluating...
Hi Michiel,
Please check the following articles
Hi!
Thanks for the reply, from what I read the schema changes are not applied automatically when deploying a newer version of a custom Sitefinity module.
you only need to execute it against the database and your migration will be done.
Does that mean that after deploying an updated Sitefinity module we also need to run queries against the database?
Hello Michiel,
If you have changes to the database you should run scripts to update the schema. Each module has a method Upgrade
public override void Upgrade(SiteInitializer initializer, Version upgradeFrom)
where you can place a custom logic that checks for a module version and performs necessary updates to the database.
Kind regards,
Ivan Dimitrov
the Telerik team
Ok, I will have alook at that, thanks!