wrap db and cursor pointers into ocaml block with tag Abstract_tag.