sqlite3.dart icon indicating copy to clipboard operation
sqlite3.dart copied to clipboard

Please support backup API

Open glanium opened this issue 4 years ago • 2 comments

SQLite3 has backup APIs. https://sqlite.org/backup.html if possible, please support it.

and if possible, support backup for moor??

thx.

glanium avatar Jan 08 '21 15:01 glanium

Can you use VACUUM INTO to backup databases?

simolus3 avatar Jan 08 '21 16:01 simolus3

can but documentation says

The VACUUM INTO command is transactional in the sense that the generated output database is a consistent snapshot of the original database. However, if the VACUUM INTO command is interrupted by an unplanned shutdown or power lose, then the generated output database might be incomplete and corrupt. Also, SQLite does not invoke fsync() or FlushFileBuffers() on the generated database to ensure that it has reached non-volatile storage before completing

and

This means that when VACUUMing a database, as much as twice the size of the original database file is required in free disk space.

So I wanna use backup api if possible

glanium avatar Jan 08 '21 19:01 glanium