SQL/MX 3.2 Programming Manual for C and COBOL (H06.25+, J06.14+)

Contents
HP NonStop SQL/MX Release 3.2 Programming Manual for C and COBOL663854-002
v
7. Static Rowsets
Declare Required Host Variables 6-4
Declare the Cursor 6-4
Initialize the Host Variables 6-5
Open the Cursor 6-5
Retrieve the Values 6-6
Process the Retrieved Values 6-7
Fetch the Next Row 6-10
Close the Cursor 6-11
Using Date-Time and INTERVAL Data Types 6-12
Standard Date-Time Example
6-12
Nonstandard SQL/MP DATETIME Example
6-13
Interval Example 6-13
Using Floating-Point Data Types 6-14
Considerations When Using a Cursor 6-14
Cursor Position 6-15
Cursor Stability 6-15
Cursor Sensitivity 6-16
7. Static Rowsets
What Are Rowsets? 7-1
Using Rowsets 7-2
Declaring Host Variable Arrays as Rowsets 7-2
Considerations for Rowset Size 7-3
Specifying Rowset Arrays 7-4
Using Rowset Arrays for Input 7-5
Using Rowset Arrays for Output
7-6
Using Rowset Arrays in DML Statements 7-6
Selecting Rows Into Rowset Arrays
7-6
Selecting Rowsets With a Cursor
7-15
Inserting Rows From Rowset Arrays
7-17
Updating Rows by Using Rowset Arrays 7-20
Deleting Rows by Using Rowset Arrays
7-22
Specifying Size and Row ID for Rowset Arrays
7-23
Limiting the Size of the Input Rowset 7-25
Limiting the Size of the Input Rowset When Declaring a Cursor 7-26
Limiting the Size of the Output Rowset
7-27
Using the Index Identifier
7-28
Specifying Rowset-Derived Tables 7-31
Using Rowset-Derived Tables in DML Statements 7-32