DbResult Class ReferenceThis class represents result of SQL query.
More...
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Public Member Functions | |
Dataset operations | |
| virtual void | cancel () |
| Cancel query processing. | |
| virtual int | columns () const =0 |
| Get number of columns. | |
| virtual bool | fetchRow ()=0 |
| Fetches next row from result. | |
| virtual const DbColumn & | getColumn (int pIndex) const =0 |
| Get column description. | |
Data Access | |
Those functions returns data from current row converting internal data representation to return data type. Field in row can be specified using column index or field name. Column index starts from zero. If SQL type that driver returned is different from returned type, then SQL type is converted to type to return. If conversion fails, then DataException is thrown. | |
| tm | getDate (int pField) const |
| Get field as date value. | |
| tm | getDate (const char *pField) const |
| Get field as date value. | |
| double | getDouble (int pField) const |
| Get field as double value. | |
| double | getDouble (const char *pField) const |
| Get field as double value. | |
| long | getInt (int pField) const |
| Get field as int value. | |
| long | getInt (const char *pField) const |
| Get field as int value. | |
| const char * | getString (int pField) const |
| Get field as string value. | |
| const char * | getString (const char *pField) const |
| Get field as string value. | |
| bool | isNull (int pField) const |
| Check if field contains null value. | |
| bool | isNull (const char *pField) const |
| Check if field contains null value. | |
Static Public Attributes | |
| static const struct tm | sInvalidTm |
| Invalid date and time structure returned for NULL values. | |
Protected Member Functions | |
| DbResult () | |
| Default constructor. | |
| virtual bool | doCheckNull (int pField) const =0 |
| Driver specific implementation for isNull. | |
| virtual struct tm | doGetDate (int pField) const =0 |
| Driver specific implementation for getDate. | |
| virtual double | doGetDouble (int pField) const =0 |
| Driver specific implementation for getDouble. | |
| virtual long | doGetInt (int pField) const =0 |
| Driver specific implementation for getInt. | |
| virtual const char * | doGetString (int pField) const =0 |
| Driver specific implementation for getString. | |
| virtual int | getColumnIndex (const char *pColumnName) const =0 |
| Driver specific implementation for getting column index by name. | |
It allows to discover column names and get data from database as one of four C types.
|
|
Cancel query processing. This operation can be one only once for DbResult and currently is supported for ODBC driver only. |
|
|
Get number of columns.
|
|
|
Driver specific implementation for getDate.
|
|
|
Driver specific implementation for getDouble.
|
|
|
Driver specific implementation for getInt.
|
|
|
Driver specific implementation for getString.
|
|
|
Fetches next row from result. If database does not support processing multiple queries send on the same connection fetchRow() must return false before next query can be send on the same connection.
|
|
|
Get column description.
|
|
|
Driver specific implementation for getting column index by name.
|
|
|
Get field as date value.
|
|
|
Get field as date value.
|
|
|
Get field as double value.
|
|
|
Get field as double value.
|
|
|
Get field as int value.
|
|
|
Get field as int value.
|
|
|
Get field as string value.
|
|
|
Get field as string value.
|
|
|
Check if field contains null value.
|
|
|
Check if field contains null value.
|
| Documentation |
|---|
| Quick start |
| Examples |
| Search |
| API Documentation |
|---|
| Class hierarchy |
| Member index |
| API Reference |
| Store filters |
| Store table macros |