Programming Guide |
Fetches the first page of rows associated with the default or named
SELECT
cursor
DBMS [WITH CURSOR cursor] CONTINUE_TOP
- WITH CURSOR
cursor
- Name of declared
SELECT
cursor. If the clause is not used, Panther uses the defaultSELECT
cursor.
DBMS CONTINUE_TOP
fetches the first screen-full of rows from the cursor's select set. If the number of rows in the select set is less than the number of occurrences in the Panther variables, the request is ignored.Some database engines automatically support
DBMS CONTINUE_TOP
. Other engines require a temporary storage file created by the commandSTORE
. If the engine needs such a file and the application tries to executeDBMS CONTINUE_TOP
without executingDBMS STORE
, Panther returns the errorDM_BAD_CMD
. For information about a specific engine, refer to "Database Drivers."
// Engines not requiring DBMS STOREproc select_all
DBMS DECLARE t_cursor FOR SELECT * FROM titles
DBMS WITH CURSOR t_cursor EXECUTE
returnproc go_to_start
DBMS WITH CURSOR t_cursor CONTINUE_TOP
return// Engines requiring DBMS STOREproc select_all
DBMS DECLARE t_cursor FOR SELECT * FROM titles
DBMS WITH CURSOR t_cursor STORE FILE
DBMS WITH CURSOR t_cursor EXECUTE
returnproc go_to_start
DBMS WITH CURSOR t_cursor CONTINUE_TOP
return
CONTINUE
,CONTINUE_BOTTOM
,
CONTINUE_DOWN
,CONTINUE_UP
,
STORE