adding support for cursors