2.3.24 The NdbOperation Class

2.3.24.1 NdbOperation Types
2.3.24.2 NdbOperation Methods

Abstract

This section discusses the NdbOperation class.

Parent class.  None

Child classes.  NdbIndexOperation, NdbScanOperation

NdbOperation Subclasses.  The following diagram shows the relationships of NdbOperation, its subclasses, and their public types:

The NdbOperation class and its subclasses.

Description.  NdbOperation represents a generic data operation. Its subclasses represent more specific types of operations. See Section 2.3.24.1.3, “The NdbOperation::Type Type” for a listing of operation types and their corresponding NdbOperation subclasses.

Methods.  The following table lists the public methods of this class and the purpose or use of each method:

MethodPurpose / Use
deleteTuple()Removes a tuple from a table
equal()Defines a search condition using equality
getBlobHandle()Used to access blob attributes
getLockHandle()Gets a lock handle for the operation
getLockMode()Gets the operation's lock mode
getNdbError()Gets the latest error
getNdbErrorLine()Gets the number of the method where the latest error occurred
getTableName()Gets the name of the table used for this operation
getTable()Gets the table object used for this operation
getNdbTransaction()Gets the NdbTransaction object for this operation
getType()Gets the type of operation
getValue()Allocates an attribute value holder for later access
insertTuple()Adds a new tuple to a table
readTuple()Reads a tuple from a table
setValue()Defines an attribute to set or update
updateTuple()Updates an existing tuple in a table
writeTuple()Inserts or updates a tuple

For detailed descriptions, signatures, and examples of use for each of these methods, see Section 2.3.24.2, “NdbOperation Methods”.

Types.  The NdbOperation class defines three public types, shown in the following table:

TypePurpose / Use
AbortOption()Determines whether a failed operation causes failure of the transaction of which it is part
LockMode()The type of lock used when performing a read operation
Type()Operation access types

For a discussion of each of these types, along with its possible values, see Section 2.3.24.1, “NdbOperation Types”.

Class diagram.  The following diagram shows all the available methods and enumerated types of the NdbOperation class:

Public methods and types of the NdbOperation class.
Note

For more information about the use of NdbOperation, see Section 1.3.2.3.1, “Single-row operations”.