Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

[Index] [Glossary] [Previous] [Next]



Location: d32dbms.h
Link against: edbms.lib

Class RDbRowConstraint

RDbRowConstraint

Support

Supported from 5.0

Description

Represents a pre-compiled SQL search-condition, which can be used to test against the current row in a rowset.

The constraint is compiled against a specific rowset, and can only be matched against the same rowset using the RDbRowSet::MatchL() function.

Defined in RDbRowConstraint:
Close(), Open()

See also:


Compiling a constraint


Open()

TInt Open(const RDbRowSet& aView,TDbQuery aCriteria);

Description

Compiles the specified SQL search-condition for matching against rows in the specified rowset. The text comparison supplied in aCriteria is used for all text columns in the constraint.

Parameters

const RDbRowSet& aView

The rowset to which the constraint will apply.

TDbQuery aCriteria

The SQL string and the text comparison mode for the constraint.

Return value

TInt

KErrNone, if successful, otherwise one of the system-wide error codes. Specifically:KErrNotFound if a column name in the SQL query does not exist.KErrArgument if Invalid or unrecognised SQL syntax was used.KErrGeneral for a column type mismatch in a predicate in the SQL query or if a date-literal in the SQL query was invalid.KErrOverflow if a number-literal in the SQL query for an integral column was too large (did not fit in a 32-bit integral representation). This can also be one of the DBMS database error codes.

See also:

[Top]


Releasing resources


Close()

void Close();

Description

Releases the resources used by the constraint before discarding the constraint object.