Patent attributes
A secondary database system is configured to act as a backup system for a primary database system. The primary database system receives a query request from a client application in advance of receiving a query. Thereafter, the primary database system determines that a routing hint in the query request indicates that workload from the query may be shifted to the secondary database system. It can then be determined that execution of the query does not involve writing data. The primary database system then determines to instruct the client application to route the query to the secondary database system based on the routing hint. The primary database system then instructs the client application to route the query to the secondary database system. The query is then compiled and executed on the secondary database system such that a replica table does not replace the source table.