The Component Integration Services access methods interact with the remote servers that contain objects represented in a query. In Adaptive Server 12.5, all interaction is done through Client-Library.
When an entire statement can be forwarded to the remote server, the statement is taken from the query plan. After any parameters have been substituted into the text of the statement, the entire statement is forwarded to the appropriate remote server.
When the Adaptive Server optimizer and plan generator are involved, the statement or fragment of a statement that is to be executed remotely is constructed from data structures contained within the query plan. The statement or fragment of a statement is then forwarded to the appropriate remote server.
The results from the remote servers are then converted into the necessary internal data types, and processed as if they were derived from local tables.
When an order by is processed by the remote server, the results may be different from what Adaptive Server would return for the same query, because the sort order is determined by the remote server, not by Adaptive Server.