#ifndef __SQL_H__ #define __SQL_H__ #include #include #include typedef std::map AssocArray; class SQLConnection : public Base { public: SQLConnection(String host, String user, String passwd, String db, int port = 3306, String socket = "", unsigned long clags = 0) throw (GeneralException); ~SQLConnection(); void query(String) throw (GeneralException); int numrows(); int numfields(); AssocArray fetchrow(); private: MYSQL con; MYSQL_RES * res; int nr, nf; MYSQL_FIELD * fields; }; #endif