1 
2 /* File:            bind.h
3  *
4  * Description:     See "bind.c"
5  *
6  * Comments:        See "notice.txt" for copyright and license information.
7  *
8  */
9 
10 #ifndef __BIND_H__
11 #define __BIND_H__
12 
13 #include "psqlodbc.h"
14 
15 /*
16  * BindInfoClass -- stores information about a bound column
17  */
18 struct BindInfoClass_ {
19 	Int4 buflen;		/* size of buffer */
20 	Int4 data_left;		/* amount of data left to read (SQLGetData) */
21 	char *buffer;		/* pointer to the buffer */
22 	SQLLEN *used;		/* used space in the buffer (for strings not counting the '\0') */
23 	Int2 returntype;	/* kind of conversion to be applied when returning (SQL_C_DEFAULT, SQL_C_CHAR...) */
24 };
25 
26 /*
27  * ParameterInfoClass -- stores information about a bound parameter
28  */
29 struct ParameterInfoClass_ {
30 	Int4 buflen;
31 	char *buffer;
32 	SQLLEN *used;
33 	Int2 paramType;
34 	Int2 CType;
35 	Int2 SQLType;
36 	UInt4 precision;
37 	Int2 scale;
38 	Oid  lobj_oid;
39 	Int4 *EXEC_used;		/* amount of data OR the oid of the large object */
40 	char *EXEC_buffer;		/* the data or the FD of the large object */
41 	char data_at_exec;
42 };
43 
44 BindInfoClass *create_empty_bindings(int num_columns);
45 void extend_bindings(StatementClass *stmt, int num_columns);
46 
47 #endif
48