Share via


Applications can request a cursor type and then execute an SQL statement that is not supported by cursors of the type requested. In such a scenario, Microsoft SQL Server Compact 3.5 tries to use an alternative cursor type that supports the properties requested of the cursor. If such a cursor cannot be created, an error is returned.

The following table lists the factors that trigger SQL Server Compact 3.5 to implicitly convert a cursor from one type to another.

Query Triggers for Conversion

Forward-only and Forward-only/read-only

Keyset-driven

Query FROM clause references no tables

Becomes static

Becomes static

Query contains:

  • Select list aggregates

  • GROUP BY

  • UNION

  • DISTINCT

  • HAVING

Error

Error

Query generates an internal work table. For example, the columns of an ORDER BY clause are not covered by an index

Becomes keyset

NA

Concepts

Types of Cursors

Choosing a Cursor Type

Updating Keyset-driven Cursors

Cursors and Locking