Visual Basic: RDO Data Control

UpdateOperation Property

See Also    Example    Applies To

Returns or sets a value that specifies if the optimistic batch update should use an Update statement or a Delete followed by an Insert.

Syntax

object**.UpdateOperation** [= value]

The UpdateOperation property syntax has these parts:

Part Description
object An object expression that evaluates to an object in the Applies To list.
value A Long integer representing the type of cursor as described in Settings:

Settings

The UpdateOperation property has these settings:

Constant Value UpdateOperation type
rdOperationUpdate 0 (Default) Uses an Update statement for each modified row.
rdOperationDelIns 1 Uses a pair of Delete and Insert statements for each modified row.

Remarks

Setting the UpdateOperation property to a value other than the ones listed here results in a runtime error.

This property determines whether the optimistic batch update cursor library uses an update statement, or a pair of delete and insert statements when sending modifications back to the database server. In the latter case, two separate operations are required to update the row. In some cases, especially where the remote system implements Delete, Insert and Update triggers, choosing the correct UpdateOperation property can significantly impact performance.

Newly added rows will always generate Insert statements and deleted rows will always generate Delete statements, so this property only applies to how the cursor library updates modified rows.