Use of [the Backup API](https://sqlite.org/c3ref/backup_finish.html#sqlite3backupinit) would be one example.