igorizr1 / wSQL

wSQL - angularJS active record module for WebSQLite database - database in the browser. U can persist your data for your PhoneGap HTML5 applications build with ionic or angular. Good solution for mobile applications with offline mode.
http://igorizr1.github.io/wSQL/
34 stars 8 forks source link

database upgrade? #8

Open ansorg opened 8 years ago

ansorg commented 8 years ago

have there been any considerations to implement a database upgrade?

I tried my luck on this but found no good place where to put the upgrade code. The async nature of the "create" code seems to make it impossible to have in a reliable way?

igorizr1 commented 8 years ago

Library do not have this feature out of the box right now. You may run queries you need after application start. But I'm not sure this is something u need. And this will not work smooth. Or probably u may hardcode function which will check the application version on start. And in case of migration is required select all data. Drop db and create new structure and insert migrated data.

Something like that. But migrations are not supported yet. Sorry