On 3/29/17, Hick Gunter <h...@scigames.at> wrote:
> The Close (1) in the second program is closing (=deleting) the ephemeral
> table. I have no idea if this would also be handled in Halt or not.

OP_Halt always closes all open cursors.  Calling sqlite3_reset() does
too.  In fact, it's the same block of code that does both.

One could omit all OP_Close opcodes and I think everything would still
work.  But sometimes an OP_Close can free up resources sooner rather
than later.  Also, some b-tree operations are faster if there is only
a single open cursor on that b-tree, and so it is advantageous to keep
the number of open cursors to a minimum.
-- 
D. Richard Hipp
d...@sqlite.org
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to