As noted in step 4 in “Failover handling”, all cursors that are re-created due to a failover are automatically repositioned by OpenSwitch to the same row as the cursor that was sitting on the primary server. This has several implications concerning application performance and reliability.
To perform this repositioning, OpenSwitch tracks the number of rows that have been explicitly fetched by the client application. During the repositioning process, an identical number of fetches are performed against the secondary server to place the cursor on the appropriate row. Sybase recommends that client applications not use cursors to fetch unusually large result sets to avoid long delays during failover while client-side cursors are repositioned.
Repositioning is based only upon the number of rows returned; not upon row contents. Therefore, both the primary and secondary servers must be configured identically and must be synchronized with each other to avoid situations in which the cursor is restored upon an inappropriate row. In particular, avoid using cursors on partitioned tables without supplying an explicit ORDER BY clause in the cursor, otherwise, Adaptive Server cannot guarantee the order of rows returned during the cursor fetch.