WIP: cursors + integer_keys fixes