Query preprocessing prepares the query for optimization. It may change the representation of a statement so that the SQL statement Sybase IQ generates for passing to a remote server will be syntactically different from the original statement.
Preprocessing performs view expansion so that a query can operate on tables referenced by the view. Expressions may be reordered and subqueries may be transformed to improve processing efficiency. For example, some subqueries may be converted into joins.