free list

The list of pages inside an SQLite database file that are no longer in use and are waiting to be reused.

In more detail

When rows are deleted, SQLite by default neither shrinks the file nor erases the old bytes; it adds emptied pages to this list, so deleted data can often be recovered by reading the raw file. The secure_delete setting overwrites deleted content with zeros, and the vacuum command rebuilds the file without the unused pages. The fast option of secure_delete only overwrites where it costs no extra disk writes, so data may still survive in free pages.

Examples

PRAGMA secure_delete=ON
secure_delete OFF: rows visible 0, note still in file: True
PRAGMA freelist_count;

Related terms

Taught in

References