]> git.ktnx.net Git - mobile-ledger.git/commit
fix db migration to surrogate IDs (final step)
authorDamyan Ivanov <dam+mobileledger@ktnx.net>
Thu, 25 Mar 2021 21:34:31 +0000 (23:34 +0200)
committerDamyan Ivanov <dam+mobileledger@ktnx.net>
Thu, 25 Mar 2021 21:34:31 +0000 (23:34 +0200)
commit46e0bf1956530342f9413d6bc8f8df45e06ca922
tree78869676868f0e2823ec1457189283afc7cde99e
parent2de3d8a8c96e78f4ab89880be9fab05735acc910
fix db migration to surrogate IDs (final step)

the cleanest approach is to create all new tables, move the data, and
then drop/rename them, followed by index creation

fixes a problem with transaction_accounts being empty because the
profiles table was dropped

requires foreign_keys pragma (set outside transaction control) so that
the declare foreign keys to the new tables get renamed with the tables
app/src/main/res/raw/db_59.sql