Query dispatcher
The function of the dispatcher is to route the query request to either CQE or SQE, depending on the attributes of the query. All queries are processed by the dispatcher. It cannot be bypassed.
Currently, the dispatcher routes an SQL statement to CQE if it finds that the statement references or contains any of the following:
- INSERT WITH VALUES statement or the target of an INSERT with subselect statement
- tables with Read triggers
- Read-only queries with more than 1000 dataspaces, or updatable queries with more than 256 dataspaces.
- DB2® Multisystem tables
- multi-format logical files
- non-SQL queries, for example the QQQQry API, Query/400, or OPNQRYF
As new functionality is added in the future, the dispatcher will route more queries to SQE and decreasingly fewer to CQE.