SMA2 icon indicating copy to clipboard operation
SMA2 copied to clipboard

Local database schema changes (migrations) after release

Open nicanorgarcia opened this issue 6 years ago • 2 comments

We recently found that if a previous version of the database was installed and the application was updated (new build), the app would crash (in this case, new tables were not found).

We need to implement a way to update the database if the schema is changed once the app is released.

nicanorgarcia avatar Oct 23 '18 16:10 nicanorgarcia

Shouldn't this be a well supported scenario? We aren't the only people that need database migrations

AKuederle avatar Oct 24 '18 07:10 AKuederle

This is pretty straightforward to solve. Every Database has a unique version ID. If this ID does not match the most recent one, the database should provide (implement) the migration to transfer content from the old version to the most recent one. So I would not consider this a bug. It sounds more like missing code.

PKlumpp avatar Nov 01 '18 12:11 PKlumpp