OK, will try that. sqlite3_release_memory doesn't have the DB connection as an argument, but found sqlite3_db_release_memory and that has that as an argument and that may work better.
RBS On Thu, Jan 7, 2016 at 6:05 AM, Scott Hess <shess at google.com> wrote: > On Wed, Jan 6, 2016 at 3:03 PM, Bart Smissaert <bart.smissaert at gmail.com> > wrote: > > > Have compiled sqlite3.dll (latest) compiled with > ENABLE_MEMORY_MANAGEMENT, > > but sofar > > not been able yet to make sqlite3_release_memory produce anything else > than > > 0. > > What would be the simplest way to make this happen? > > I don't want to do this with C coding, so it should be some SQL scenario > or > > to do with simple > > SQLite functions such as sqlite3_step, _prepare, -finalize etc. > > > Last time I was paying attention to this, I believe that I found that the > biggest effect was to free unpinned pages from the page cache. So it might > not free pages if you're in a transaction, for instance. I would guess > that if you had memory-mapped mode on and are doing only reads, there would > be no pages to free (mmap pages aren't in the page cache). So you should > see results if you start a transaction, do a few update statements, commit > the transaction, the call sqlite3_release_memory(db). > > -scott > _______________________________________________ > sqlite-users mailing list > sqlite-users at mailinglists.sqlite.org > http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users >