diff options
author | randomdan <randomdan@localhost> | 2006-07-08 16:32:05 +0000 |
---|---|---|
committer | randomdan <randomdan@localhost> | 2006-07-08 16:32:05 +0000 |
commit | 2a1fa15d8baa4eda37e17b2e9362f8bde17a939d (patch) | |
tree | 09386e52320b7c52a521ab56fc7553896e639dcd /libodbcpp/command.h | |
download | libdbpp-odbc-2a1fa15d8baa4eda37e17b2e9362f8bde17a939d.tar.bz2 libdbpp-odbc-2a1fa15d8baa4eda37e17b2e9362f8bde17a939d.tar.xz libdbpp-odbc-2a1fa15d8baa4eda37e17b2e9362f8bde17a939d.zip |
libcodbcpp initial release
Diffstat (limited to 'libodbcpp/command.h')
-rw-r--r-- | libodbcpp/command.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/libodbcpp/command.h b/libodbcpp/command.h new file mode 100644 index 0000000..8e59c76 --- /dev/null +++ b/libodbcpp/command.h @@ -0,0 +1,38 @@ +#ifndef ODBC_COMMAND_H +#define ODBC_COMMAND_H + +#include <vector> +#include "connection.h" +#include "timetypepair.h" + +namespace ODBC { + class Param; + class Command { + typedef std::vector<Param*> Params; + public: + Command(const Connection&, String sql); + virtual ~Command() = 0; + + void bindParamI(unsigned int i, int val); + void bindParamI(unsigned int i, unsigned int val); + void bindParamF(unsigned int i, double val); + void bindParamF(unsigned int i, float val); + void bindParamS(unsigned int i, const char *); + void bindParamS(unsigned int i, const unsigned char *); + void bindParamS(unsigned int i, const unsigned char *, size_t); + void bindParamS(unsigned int i, std::string); + void bindParamS(unsigned int i, String); + void bindParamT(unsigned int i, struct tm *); + void bindParamT(unsigned int i, time_t); + + const String sql; + protected: + SQLHSTMT hStmt; + private: + Params params; + }; + +} + +#endif + |