Browse Prior Art Database

Updateable Scrollable Cursors

IP.com Disclosure Number: IPCOM000104381D
Original Publication Date: 1993-Apr-01
Included in the Prior Art Database: 2005-Mar-19
Document File: 6 page(s) / 250K

Publishing Venue

IBM

Related People

Boykin, JR: AUTHOR [+4]

Abstract

Disclosed is a method for extended SQL scrollable cursors to allow updates. Two update models -- static and dynamic -- are provided.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 17% of the total text.

Updateable Scrollable Cursors

      Disclosed is a method for extended SQL scrollable cursors to
allow updates.  Two update models -- static and dynamic -- are
provided.

      Scrollable cursors are defined to be read-only in the current
International Standards Organization (ISO) definition of SQL2, but
there are many requirements for updateable scrollable cursors.
However, the introduction of updateability raises many questions,
which we have resolved by providing a choice of models.

      This invention is best described through the syntax of the SQL
statements which implement it, and notes on the use of those
statements.  Some terminology will be helpful:

o   A cursor is "serial" if it permits the rows of its result table
    to be fetched once and once only, in a predetermined order.
o   A cursor is "scrollable" if it permits arbitrary navigation
    through the rows of the result table.
o   A cursor is "updateable" if fetched rows can be modified, and can
    cause the base table of the cursor to be modified.

      Syntax and semantics are proposed for an updateable scrollable
cursor capability.  This capability is designed to be upward
compatible from the current SQL updateable serial cursor and the
proposed ISO non-updateable scrollable cursor.

      The DECLARE CURSOR statement defines a cursor.  It is extended
here to support two flavors of updateable, scrollable cursors.

      Invocation - This statement can only be embedded in an
application program.

Syntax

+-------------------------------------------------------+
|                                                       |
| >>--DECLARE--cursor-name--.---------------------.---> |
|                           '-.---------.--SCROLL-'     |
|                             |-STATIC--|               |
|                             '-DYNAMIC-'               |
|                                                       |
| >--CURSOR--.-----------.--FOR-----------------------> |
|            '-WITH HOLD-'                              |
|                                                       |
| >--.-select-statement-.---------------------------->< |
|    '-statement-name---'                               |
|                                                       |
+-------------------------------------------------------+

Description
cursor-name      A cursor with the specified name is defined.
                 The name must not be the same as the name of
                 another cursor declared in your source program.

 ...