diff options
| author | fusion32 <marcopuzziello@gmail.com> | 2025-10-10 15:14:02 -0300 |
|---|---|---|
| committer | fusion32 <marcopuzziello@gmail.com> | 2025-10-10 15:22:27 -0300 |
| commit | 46c653293381dcc1188013d3e2c3f7587a199dc4 (patch) | |
| tree | 0b9776f73d6e2afcd9104cf400dc5e345fcdcbea /sqlite/README.txt | |
| parent | cc4873e33866ba86561774a7e55449d59367661e (diff) | |
| download | querymanager-46c653293381dcc1188013d3e2c3f7587a199dc4.tar.gz querymanager-46c653293381dcc1188013d3e2c3f7587a199dc4.zip | |
organize database configs and schema files + compilation guards
Diffstat (limited to 'sqlite/README.txt')
| -rw-r--r-- | sqlite/README.txt | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sqlite/README.txt b/sqlite/README.txt new file mode 100644 index 0000000..26f782a --- /dev/null +++ b/sqlite/README.txt @@ -0,0 +1,10 @@ + The query manager will properly initialize and upgrade the database schema +based on files in this folder. The initial schema should be in `schema.sql` and +upgrades should be in `upgrade-N.sql` where N is a number starting from 1. The +`upgrade-N.sql` file should take the database from version N to N + 1. + The only restriction to these files is that they can't have transaction +statements ("BEGIN", "ROLLBACK", "COMMIT") because the query manager will +already bundle them into a transaction that also sets `user_version`, and +and nested transactions aren't allowed. + The current database version can be retrieved with the "PRAGMA user_version" +query in the SQLite shell.
\ No newline at end of file |
