Example table for scrollable cursors

The examples in this section are executed by a scrollable cursor. To generate the data in Table 19-4, execute:

select emp_id, fname, lname
from emp_tab
where emp_id > 2002000

The base table, emp_tab, is a datarows-locking table with a clustered index on the emp_id field. “Row position” is an imaginary column, whose values represent the position of each row in the result set. The result set in this table is used in the examples in the following sections, which illustrate both insensitive and semi-sensitive cursors.

Table 19-4: Results of executing select statement

Row position

employee id

first name

last name

1

2002010

Mari

Cazalis

2

2002020

Sam

Clarac

3

2002030

Bill

Darby

4

2002040

Sam

Burke

5

2002050

Mary

Armand

6

2002060

Mickey

Phelan

7

2002070

Sam

Fife

8

2002080

Wanda

Wolfe

9

2002090

Nina

Howe

10

2002100

Sam

West