6 #include "../sqlite3db.h"
\r
8 #if SQLITE_VERSION_NUMBER<3006006
\r
9 #error "Your version of SQLite is too old! 3.6.6.2 or later is required."
\r
19 DB(const std::string &filename);
\r
22 const bool Open(const std::string &filename);
\r
25 const int GetLastResult() { return m_lastresult; } // gets result of last action taken - standard sqlite3 return codes
\r
26 const int GetLastError(std::string &errormessage); // gets last error of this database
\r
28 const bool IsOpen();
\r
30 const bool Execute(const std::string &sql); // executes a statement returing true if successful
\r
31 const bool ExecuteInsert(const std::string &sql, long &insertid); // call when inserting data and the insertid of the row inserted is needed, otherwise Execute can be called if the row id is not needed
\r
32 Recordset Query(const std::string &sql); // executes a statement returning a recordset
\r
33 Statement Prepare(const std::string &sql); // prepares a statement returning the statement object
\r
35 const int SetBusyTimeout(const int ms); // sets busy timeout in ms. SQLite will wait for a lock up to this many ms before returning SQLITE_BUSY
\r
37 sqlite3 *GetDB() { return m_db; }
\r
48 #endif // _sqlite3db_
\r