Refetching Rows with a Cursor
Go Up to Fetching Rows with a Cursor
The only supported cursor movement is forward in sequential order through the active set.
To revisit previously fetched rows, close the cursor and then reopen it with another OPEN
statement. For example, the following statements close the DEPT_EMP
cursor, then recreate it, effectively repositioning the cursor at the start of the DEPT_EMP
results table:
EXEC SQL CLOSE DEPT_EMP; EXEC SQL OPEN DEPT_EMP;