Notes: SQLite

SQLite settings

PRAGMA journal_mode = WAL;
Turns on write ahead log, allows for multiple concurrent readers.
PRAGMA synchronous = 1;
Turns on normal synchronous mode, allows for faster transactions. Safe when used in combination with WAL.
PRAGMA busy_timeout = 5000;
As only one write can happen at a time, how long should a write command wait in the queue before erroring.
PRAGMA foreign_keys = ON;
Foreign key enforcing isn't enabled by default.


The value is a signed integer, stored in 0, 1, 2, 3, 4, 6, or 8 bytes depending on the magnitude of the value. As soon as its pulled off disk and into memory it becomes an 8-byte signed integer.
The value is a floating point value, stored as an 8-byte IEEE floating point number.
The value is a text string, stored using the database encoding (UTF-8, UTF-16BE or UTF-16LE).
The value is a blob of data, stored exactly as it was input.
No data.

Further details