|
|
|
class TDbQuery;
A wrapper for an SQL string combined with a text comparison mode.
An instance of the class is used as a parameter to RDbView::Prepare(RDbDatabase &,const TDbQuery &,TAccess), RDbRowSet::FindL(TDirection,TDbQuery) and RDbRowConstraint::Open(const RDbRowSet &,TDbQuery).
The evaluation of SQL queries or constraints depends on how Text columns are compared so every SQL string is accompanied by a member of the TDbTextComparison enumeration to indicate how comparison is done.
If the SQL string contains a LIKE clause with * (asterisks) wildcard then the characters between them must be no longer than length 255. If only one * exists then the length is taken from the start and to the end of the clause. However, if the clause contains a ? (question mark) wildcard within it then the characters between must be no longer than length 253.
Defined in TDbQuery:
Comparison()constReturns the text comparison mode for the query object.Query()constReturns the SQL string in the query object.TDbQuery(const TDesC &,TDbTextComparison)Constructs a query object from an SQL string and a text comparison mode.TDbTextComparisonRepresents different ways of comparing Text and LongText columns.RDbView::Prepare(RDbDatabase &,const TDbQuery &,TAccess)Prepares the view object for evaluating an SQL select-statement.RDbRowSet::FindL(TDirection,TDbQuery)Searches through a rowset for a row which fulfils an SQL search-condition. The s...RDbRowConstraint::Open(const RDbRowSet &,TDbQuery)Compiles the specified SQL search-condition for matching against rows in the spe...inline TDbQuery(const TDesC &aQuery, TDbTextComparison aComparison=EDbCompareNormal);
Constructs a query object from an SQL string and a text comparison mode.
Note that no copy is made of the descriptor passed; it is stored by reference in the query object.
|
inline const TDesC& Query() const;
Returns the SQL string in the query object.
|
inline TDbTextComparison Comparison() const;
Returns the text comparison mode for the query object.
|