On 5 Apr 2019, at 1:45pm, Arthur Blondel <[email protected]> wrote:

> I'm limited in space so when the DB is full (when sqlite3_exec() returns 
> SQLITE_FULL when I try to insert a new row), I remove the oldest row

If SQLite returns SQLITE_FULL you cannot reliably do anything else to the 
database.  Because even if your next command is DELETE, SQLite needs to 
temporarily use /more/ disk space for the journal until that transaction is 
committed.  So your DELETE command can fail too.

Do not use this behaviour.  Instead monitor the free space on the database 
volume and delete rows when you have only a little space free.

Simon.
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to