Another option: Copy the meta-data to an in-memory-DB. As you "load all meta
data into memory" anyway this seems a viable option.
ATTACH ':memory:' AS mem
INSERT INTO mem.Table SELECT * FROM Table
(repeat for each table, you may want to create/recreate constraint and
indices in the attached DB, of course)
During this copy, you can make the schema adjustments.
---
I'm storing both raw and meta data in an SQLite DB, create that
in-memory-copy only for the meta data, and use this as the
in-memory-representation - no separate C++ class graph for the data
structure.
(There's basically a C++ class for each table holding one row, and fille on
demand from the in memory db. It's not blazingly fast - you can quickly
accumulate a few ms for a bunch of queries - but good enough certainly, and
fun to use.)
When creating that "snapshot", I make adjustments to the schema, so read
compatibility is in one place.
--
View this message in context:
http://sqlite.1065341.n5.nabble.com/How-to-upgrade-a-DB-without-write-access-to-its-file-or-to-the-direction-it-s-in-tp70408p70574.html
Sent from the SQLite mailing list archive at Nabble.com.
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users