SQL$HELP_OLD72.HLB  —  DECLARE  CURSOR  Format
  DECLARE <cursor-name> --------------------+
  +-----------------------------------------+
  +-+-+----------------+--> TABLE CURSOR ---+----------------+-+
    | +-> INSERT ONLY -+                    +-> with-clause -+ |
    | +-> READ ONLY ---+                                       |
    | +-> UPDATE ONLY -+                                       |
    | +--------------------------------------------------------+
    | +-> FOR -> select-expr --+----------------------+--+
    |                          +-> for-update-clause -+  |
    |      +---------------------------------------------+
    |      +-+--------------------+----------------------------+-->
    |        +-> optimize-clause -+                            |
    ++---------------++---------+-+-> LIST CURSOR FOR SELECT + |
     +> READ ONLY ---++> SCROLL + |                          | |
     +> INSERT ONLY --------------+                          | |
    +--------------------------------------------------------+ |
    +> <column-name> WHERE CURRENT OF <table-cursor-name> -----+

  with-clause =

  ---> WITH --> HOLD -+-------------------------------+->
                      +-> PRESERVE --+-> ON COMMIT ---+
                                     +-> ON ROLLBACK -+
                                     +-> ALL ---------+
                                     +-> NONE --------+

  select-expr =

  -+-+->  select-clause  ------------+-+------+
   | +-> ( select-expr )  -----------+ |      |
   | +->   TABLE table-ref ----------+ |      |
   +------ select-merge-clause <-------+      |
     +------------------- <-------------------+
     +-+--------------------+--+------------------+--+--------------------+->
       +-> order-by-clause -+  +-> offset-clause -+  +-> limit-to-clause -+

  for-update-clause =

  --> FOR UPDATE -+-------------------------+->
                  +-+-> OF <column-name> -+-+
                    +-------- , <---------+

  optimize-clause =

  --+---------------------------------------------------------------+--->
    +-> OPTIMIZE --+-+-> FOR -+-> FAST FIRST --------+----------+-+-+
                   | |        +-> TOTAL TIME --------+          | |
                   | |        +-> SEQUENTIAL ACCESS -+          | |
                   | +-> USING <outline-name> ------------------+ |
                   | +-> WITH -+-> DEFAULT  --+-> SELECTIVITY  -+ |
                   | |         +-> SAMPLED  --+                 | |
                   | |         +-> AGGRESSIVE +                 | |
                   | +-> AS <query-name> -----------------------+ |
                   +---------------- <----------------------------+
Close Help