Closed programonauta closed 3 years ago
Hi, I will check what could be the issue.. are you checking against the current clone of this repo or any particular release?
Hi @siara-cc, I've installed through Arduino IDE and the "more information" button directs to this repository.
Anyway, it could be anything I'm doing wrong?
Hi, as of now unable to determine why it does not work. Auto-vacuum cannot be enabled by adding it on top of ino file.. you will have to change config_ext.h
.
Another option would be to insert remaining records to another DB when number of deleted records become significant. Or maintain datewise or monthwise db files and delete them.
Shouldn't #define SQLITE_OMIT_AUTOVACUUM 1
also be undefined in config_ext.h in order for auto-vacuum to work?
Also how memory intensive is a VACUUM operation? I tried to do it but I got an "out of memory" error, I only tested on VFAT though, it just seems to work better there (though probably because it isn't sharing data bandwidth with program code).
According to my understanding, Vacuum is different from Auto-vacuum and requires more resources. See https://sqliteviewer.com/blog/sqlite-vacuum-and-auto-vacuum-commands/.
Vacuum
copies to a new database so might get into trouble with limitation of number of simulataneous files and memory, so I have disabled it.
Hi,
I'm using sqlite3 in my WeMos WiFi&Bluetooth Battery board in SPIFFS, and everything work fine.
But I'd like to optimize the database size. So, I tried to run the command "VACUUM;" with sqlite3_exec function, but I received an error: "disk I/O error".
My code:
So I tried to initialize #define SQLITE_DEFAULT_AUTOVACUUM 1 in the firsts lines of my sketch.
How could I reduce the size of my sqlite file on SPIFFS?
Thanks