Progress
Embedded SQL-92
Guide and Reference


SELECT Statement

Dynamic SELECT statements are executed differently since they return data and information beyond the scope of the SQLCA. The statements used for dynamic SELECT include OPEN, FETCH, and CLOSE.

A simple form of a dynamic SELECT statement allows queries whose SELECT list is known but whose search criteria or ordering might vary. Follow these general steps to process a dynamic SELECT statement:

  1. PREPARE the statement.
  2. DECLARE a cursor.
  3. OPEN the cursor.
  4. FETCH rows using the cursor.
  5. CLOSE the cursor.

Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095