aboutsummaryrefslogtreecommitdiff
path: root/test/cli
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2021-05-24 14:40:37 +0200
committerEven Rouault <even.rouault@spatialys.com>2021-05-24 14:40:37 +0200
commitee04c2725f0f8b163ae242935a2ca21dbcc17620 (patch)
treebaf6b0b52fa7295ade9ccab36c1bdd0323232f8d /test/cli
parentc44a3008b0edb5197b0efa584d3f5f7e18d79b0b (diff)
downloadPROJ-ee04c2725f0f8b163ae242935a2ca21dbcc17620.tar.gz
PROJ-ee04c2725f0f8b163ae242935a2ca21dbcc17620.zip
Database: decrease DB size by using WITHOUT ROWID tables
None of our tables are indexed by a INTEGER PRIMARY KEY, but most of them are by a (auth_name, code) primary key. Consequently they can benefit from being created as WITHOUT ROWID tables (https://sqlite.org/withoutrowid.html), which avoids an index to be created on the rowid we don't use. WITHOUT ROWID is a feature added in SQLite 3.8.2, so as our baseline is 3.11, we can use it. This decreases the DB size from 7,749,632 to 7,229,440 bytes, without any measurable consequence on performance.
Diffstat (limited to 'test/cli')
-rw-r--r--test/cli/testprojinfo_out.dist2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/cli/testprojinfo_out.dist b/test/cli/testprojinfo_out.dist
index 3482c90e..9f2fb22b 100644
--- a/test/cli/testprojinfo_out.dist
+++ b/test/cli/testprojinfo_out.dist
@@ -1557,7 +1557,7 @@ Testing projinfo --dump-db-structure | head -n 5
CREATE TABLE metadata(
key TEXT NOT NULL PRIMARY KEY CHECK (length(key) >= 1),
value TEXT NOT NULL
-);
+) WITHOUT ROWID;
CREATE TABLE unit_of_measure(
Testing projinfo --dump-db-structure --output-id HOBU:XXXX EPSG:4326 | tail -n 4