2.2.3.11 CPMGetRowsIn
The CPMGetRowsIn message requests rows from a query. The format of the CPMGetRowsIn message that follows the header is shown in the following diagram.
|
0 |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
1 0 |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
2 0 |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
3 0 |
1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
_hCursor |
|||||||||||||||||||||||||||||||
|
_cRowsToTransfer |
|||||||||||||||||||||||||||||||
|
_cbRowWidth |
|||||||||||||||||||||||||||||||
|
_cbSeek |
|||||||||||||||||||||||||||||||
|
_cbReserved |
|||||||||||||||||||||||||||||||
|
_cbReadBuffer |
|||||||||||||||||||||||||||||||
|
_ulClientBase |
|||||||||||||||||||||||||||||||
|
_fBwdFetch |
|||||||||||||||||||||||||||||||
|
eType |
|||||||||||||||||||||||||||||||
|
_chapt |
|||||||||||||||||||||||||||||||
|
SeekDescription (variable) |
|||||||||||||||||||||||||||||||
|
... |
|||||||||||||||||||||||||||||||
-
_hCursor (4 bytes): A 32-bit value representing the handle from the CPMCreateQueryOut message identifying the query for which to retrieve rows.
-
_cRowsToTransfer (4 bytes): A 32-bit unsigned integer indicating the maximum number of rows that the client will receive in response to this message.
-
_cbRowWidth (4 bytes): A 32-bit unsigned integer indicating the length of a row, in bytes.
-
_cbSeek (4 bytes): A 32-bit unsigned integer indicating the size of the message beginning with eType.
-
_cbReserved (4 bytes): A 32-bit unsigned integer indicating the size, in bytes, of a CPMGetRowsOut message (without the Rows and SeekDescriptions fields). This value in this field is added to the value of the _cbSeek field, and then is to be used to calculate the offset of Rows field in the CPMGetRowsOut message.
-
_cbReadBuffer (4 bytes): A 32-bit unsigned integer.
Note This field MUST be set to the maximum of the value of _cbRowWidth or 1000 times the value of _cRowsToTransfer, rounded up to the nearest 512 byte multiple. The value MUST NOT exceed 0x00004000.
-
_ulClientBase (4 bytes): A 32-bit unsigned integer indicating the base value to use for pointer calculations in the row buffer. If 64-bit offsets are being used, the reserved2 field of the message header is used as the upper 32-bits and _ulClientBase as the lower 32-bits of a 64-bit value. See section 2.2.3.12.
-
_fBwdFetch (4 bytes): A 32-bit unsigned integer indicating the order in which to fetch the rows that MUST be set to one of the following values.
-
Value Meaning 0x00000000
The rows are to be fetched in forward order.
0x00000001
The rows are to be fetched in reverse order.
-
eType (4 bytes): A 32-bit unsigned integer that MUST contain one of the following values indicating the type of operation to perform.
-
Value Meaning 0x00000000
There is no SeekDescription; the SeekDescription field is omitted.
eRowSeekNext
0x00000001SeekDescription contains a CRowSeekNext structure.
eRowSeekAt
0x00000002SeekDescription contains a CRowSeekAt structure.
eRowSeekAtRatio
0x00000003SeekDescription contains a CRowSeekAtRatio structure.
eRowSeekByBookmark
0x00000004SeekDescription contains a CRowSeekByBookmark structure.
-
SeekDescription (variable): This field MUST contain a structure of the type indicated by the eType value.
The _fBwdFetch argument affects the retrieval of rows from the results. Rows are taken from the beginning of the seek in the direction determined by the value of _fBwdFetch. In the following, a number of records have been retrieved. The figure shows how the buffer will be filled depending on the value of the _fBwdFetch. For more information about the structure of the buffer, see CPMGetRowsOut.
Figure 2: Effect of _fBwdFetch Parameter
Notice that the _fBwdFetch argument changes the order in which records are presented for placement in the buffer but does not change the order (forward order) in which the buffer itself is filled.