CppSQLite3Query CppSQLite3Statement::execQuery() { checkDB(); checkVM(); int nRet = sqlite3_step(mpVM); if (nRet == SQLITE_DONE) { // no rows return CppSQLite3Query(mpDB, mpVM, true/*eof*/, false); } else if (nRet == SQLITE_ROW) { // at least 1 row return CppSQLite3Query(mpDB, mpVM, false/*eof*/, false); } else { nRet = sqlite3_reset(mpVM); const char* szError = sqlite3_errmsg(mpDB); throw CppSQLite3Exception(nRet, (char*)szError, DONT_DELETE_MSG); } }
bool CSQLite3Query::eof(void) { checkVM(); return m_bEof; }
bool CppSQLite3Query::eof() { checkVM(); return mbEof; }
int CppSQLite3Query::numFields() { checkVM(); return mnCols; }