3.1.5.2.2 Receiving a CPMCreateQueryIn Request
When the server receives a CPMCreateQueryIn message request from a client, the server MUST do the following:
Search the ConnectedClientsIdentifiers list for the HANDLE of the named pipe over which the server has received the CPMCreateQueryIn message. If it is not present, the server MUST report a STATUS_INVALID_PARAMETER (0xC000000D) error.
Run the RunNewQuery abstract interface of the GSS. Pass in as parameters the HANDLE of the named pipe over which the server has received the CPMCreateQueryIn message, along with the ColumnSet, RestrictionArray, SortSet, CCategorizationSet, RowSetProperties, PidMapper, GroupArray, and Lcid values. If the CanRunQueryNow output parameter is not true, the server MUST report a STATUS_INVALID_PARAMETER (0xC000000D) error. Otherwise, report the QueryParametersError output parameter in the reply. Details for how to report an error are specified in section 3.1.5.
Respond to the client with a CPMCreateQueryOut message by using the CursorHandlesList, fTrueSequential, and fWorkidUnique outputs obtained from the RunNewQuery abstract interface to the GSS.
Report any errors encountered during message preparation or during any abstract interface call to the GSS. The following errors are specific to this request:
E_OUTOFMEMORY: generated by any resource allocation failure on the server or service side.
STATUS_INVALID_PARAMETER: generated when any of the parameters passed in by the client are invalid. Invalid parameters are those that do not obey the corresponding data structure layout as defined for their types in this document.
STATUS_INVALID_PARAMETER_MIX: generated when the client version, as passed in this message, is smaller than 0x102.
STATUS_NO_MEMORY: generated on memory allocation errors.
STATUS_INSUFFICIENT_RESOURCES: generated on resource allocation errors. These resources could be file or pipe handles, any data structures that are specific to the implementation of the GSS, or any other resources used by the GSS implementation.
CI_E_NOT_FOUND: generated when the requested property was not found.
ERROR_INVALID_PARAMETER: this is generated by the WSS implementation on some internal errors, such as registry access failures. Implementations of the GSS can choose to do the same.
CI_E_TIMEOUT: generated on named pipe communication timeout.
E_ACCESSDENIED: generated when the client does not have permissions to access a needed resource, such as a file result or a catalog.
Any other error code can be returned, but it will be treated as informative only.