dbd/db2/dbd_db2.h

changeset 14
98192b7d4e89
child 25
2cc3feba9277
equal deleted inserted replaced
13:10c8c6f0da14 14:98192b7d4e89
1 #include <sqlcli1.h>
2 #include <sqlutil.h>
3 #include <sqlenv.h>
4 #include <dbd/common.h>
5
6 #define DBD_DB2_CONNECTION "DBD.DB2.Connection"
7 #define DBD_DB2_STATEMENT "DBD.DB2.Statement"
8
9 /*
10 * result set metadata
11 */
12
13 typedef struct _resultset {
14 SQLSMALLINT name_len;
15 SQLSMALLINT type;
16 SQLUINTEGER size;
17 SQLSMALLINT scale;
18 SQLCHAR name[32];
19 } resultset_t;
20
21 /*
22 * bind parameters
23 */
24 typedef struct _bindparams {
25 SQLCHAR *buffer;
26 SQLINTEGER len;
27 SQLINTEGER buffer_len;
28 } bindparams_t;
29
30 /*
31 * connection object implentation
32 */
33 typedef struct _connection {
34 SQLHANDLE env;
35 SQLHANDLE db2;
36 } connection_t;
37
38 /*
39 * statement object implementation
40 */
41 typedef struct _statement {
42 resultset_t * resultset;
43 bindparams_t * bind;
44 SQLSMALLINT num_result_columns; /* variable for SQLNumResultCols */
45
46 SQLHANDLE stmt;
47 SQLHANDLE db2;
48 } statement_t;
49

mercurial