3.2.4.2.4 Sending a CPMGetRowsIn Request
When the higher layer is about to receive rows data, it will provide the protocol client with a valid cursor and chapter handle and give an appropriate seek description. Typically, a higher layer is expected to do so when it has a valid cursor and/or chapter handle, and the bindings had been set with a CPMSetBindingsIn message. To access the rowset in a chapter, the higher layer is to use the chapter handle received from the server in a previous CPMGetRowsOut message.
When this request is received from the higher layer, the client MUST do the following:
Determine what unsigned integer value to specify for the _cbReadBuffer field. To determine this value, the client MUST take the maximum value from the following:
One thousand times the value of the _cRowsToTransfer field.
Value of _cbRowWidth, rounded up to the nearest 512-byte multiple.
Take the higher of these two values, up to the 16-kilobyte limit.
In cases where a single row is larger than 16 kilobytes, the server cannot return results to this query.
Specify a client base for variable-sized row data in the client address space in the _ulClientBase field.<14>
Calculate the size of seek description, and set it in the _cbSeek field.
Set the value of _cbReserved (which would act as an offset for Rows start) to the value of _cbSeek plus 0x14.
Send a CPMGetRowsIn message to the server.