Name

SQLITE_TEMP_STORE — Specify temporary storage location

Common Usage

SQLITE_TEMP_STORE=<0|1|2|3>

Default

1 (use files, allow override)

Description

This directive controls how temporary files are stored. Temporary files may either be stored on disk or in memory. Rollback journals and master journals are always stored on disk. This parameter applies to temporary databases (used to store temporary tables), materialized views and subqueries, transient indexes, and transient databases used by VACUUM. It is perfectly safe to use memory based temporary storage.

ValueTemp. storage location
0Always on disk
1Defaults to on disk, allows override
2Defaults to in memory, allows override
3Always in memory

See Also

temp_store [PRAGMA, Ap F], sqlite3_config() [C API, Ap G]

Get Using SQLite now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.