I doubt that such a function exists. What you want is essentially to retrieve count(*) in place of your selected column(s). Oracle appears to handle cursors very efficiently by not bringing back all of the rows at once, but only as it needs more to satisfy a fetch request. You could could do that “SELECT count(*)” with or without a cursor prior to fetching from your cursor, but it would take nearly as long as retrieving all of the rows from the cursor unless satisfying your WHERE clause did not require all of the table accesses (through use of indexes) needed to retrieve the data. Even then, you would only be skipping retrieval by row id. I sometimes prefer not to return any rows if there are far too many. If I don’t consider it reasonable to deal with more than 50 rows, issuing the “SELECT count(*)” with the additional restriction on rownum in the WHERE clause gives me the information I need to skip the fetches from the cursor.