remove SQLite cursors on INSERT and DELETE operations