Files
Sun1602/LogCollector/SUNLogConsole/DBHandler.h
T
2022-10-26 12:25:11 +08:00

37 lines
923 B
C++

/*------------------------------------------------------------------------------
* DBHandler.h
*------------------------------------------------------------------------------
*
*------------------------------------------------------------------------------
* All rights reserved by Jin Hye Jin (jiny7749@hotmail.com)
**----------------------------------------------------------------------------*/
#ifndef _DB_HANDLER_H_
#define _DB_HANDLER_H_
#include "DB.h"
class LogCriticalSection;
class DatabasePool;
class DBHandler
{
public:
DBHandler();
~DBHandler();
int DBConnect();
BOOL DoSQL(TCHAR * pszSQL);
void InsertError(TCHAR * szError);
protected:
DatabasePool * m_pDBPool;
LogCriticalSection * m_pDBCS;
BOOL GetSQLControlor(pDBInfo dbConnection,
SQLHDBC * hdbc,
SQLHSTMT * hstmt,
LPCTSTR szSQL);
BOOL CheckContext(TCHAR * szContext);
};
#endif //_DB_HANDLER_H_