I have a project that compiles SQLite with the following options:
-DSQLITE_SECURE_DELETE=1
-DSQLITE_THREADSAFE=1
-DSQLITE_CORE=1
-DSQLITE_ENABLE_FTS3=1
-DSQLITE_ENABLE_UNLOCK_NOTIFY=1
-DSQLITE_DEFAULT_PAGE_SIZE=32768
-DSQLITE_MAX_DEFAULT_PAGE_SIZE=32768
Hello,
My query wont use the R-Tree index if I provide an ORDER BY clause and
performance degrades considerably. Obviously I can work around with by
making the R-Tree query a subquery and sorting the results, but would
like to know why this is necessary? I've done an VACUUM and ANALYZE.
On 11-03-22 10:40 AM, Simon Slavin wrote:
Or just do a 'SELECT id FROM whatever LIMIT 1'. If you get any error, it
doesn't exist, so create it and fill it.
Or look in sqlite_master for an entry for the TABLE.
Simon.
Could also use INSERT OR IGNORE statements for the seed data if the rows