Select statement
Description
Creates a latent cursor of keys for an opened native table.
Syntax
Select table_var
Parameters
The Select statement has the following parameters.
Parameter | Description |
---|---|
table_var | Contains a file variable that was returned from a previous Open statement. |
Note: Do not add rows to a table while using the Select…ReadNext process. The addition of keys to the table can generate unpredictable results.
The order the keys are returned in is dependent on the filing system.
See Also
Example
Processing the CUSTOMERS table
declare function Set_FSError open "CUSTOMERS" To customers_table else status = Set_FSError() return end select customers_table Done = 0 loop ReadNext @ID else Done = 1 Until Done Do read @RECORD From customers_table, @ID else status = Set_FSError() return end * processing logic here ... GoSub PROCESS Repeat return 0 PROCESS: /* process the row */ return