]>
git.saurik.com Git - wxWidgets.git/blob - src/iodbc/isql.h
1 #ifndef _INTRINSIC_SQL_H
2 # define _INTRINSIC_SQL_H
4 typedef unsigned char UCHAR
;
5 typedef long int SDWORD
;
6 typedef short int SWORD
;
7 typedef unsigned long int UDWORD
;
8 typedef unsigned short int UWORD
;
10 typedef void FAR
* PTR
;
12 typedef void FAR
* HENV
;
13 typedef void FAR
* HDBC
;
14 typedef void FAR
* HSTMT
;
16 typedef signed short RETCODE
;
19 # define SQL_API __stdcall
21 # define SQL_API EXPORT CALLBACK
24 # define ODBCVER 0x0200
26 # define SQL_MAX_MESSAGE_LENGTH 512
27 # define SQL_MAX_DSN_LENGTH 32
30 # define SQL_INVALID_HANDLE (-2)
31 # define SQL_ERROR (-1)
32 # define SQL_SUCCESS 0
33 # define SQL_SUCCESS_WITH_INFO 1
34 # define SQL_NO_DATA_FOUND 100
36 /* standard SQL datatypes (agree with ANSI type numbering) */
38 # define SQL_NUMERIC 2
39 # define SQL_DECIMAL 3
40 # define SQL_INTEGER 4
41 # define SQL_SMALLINT 5
45 # define SQL_VARCHAR 12
47 # define SQL_TYPE_MIN SQL_CHAR
48 # define SQL_TYPE_NULL 0
49 # define SQL_TYPE_MAX SQL_VARCHAR
51 /* C to SQL datatype mapping */
52 # define SQL_C_CHAR SQL_CHAR
53 # define SQL_C_LONG SQL_INTEGER
54 # define SQL_C_SHORT SQL_SMALLINT
55 # define SQL_C_FLOAT SQL_REAL
56 # define SQL_C_DOUBLE SQL_DOUBLE
57 # define SQL_C_DEFAULT 99
59 # define SQL_NO_NULLS 0
60 # define SQL_NULLABLE 1
61 # define SQL_NULLABLE_UNKNOWN 2
63 /* some special length values */
64 # define SQL_NULL_DATA (-1)
65 # define SQL_DATA_AT_EXEC (-2)
68 /* SQLFreeStmt flag values */
72 # define SQL_RESET_PARAMS 3
74 /* SQLTransact flag values */
76 # define SQL_ROLLBACK 1
78 /* SQLColAttributes flag values */
79 # define SQL_COLUMN_COUNT 0
80 # define SQL_COLUMN_LABEL 18
81 # define SQL_COLATT_OPT_MAX SQL_COLUMN_LABEL
82 # define SQL_COLUMN_DRIVER_START 1000
84 # define SQL_COLATT_OPT_MIN SQL_COLUMN_COUNT
87 # define SQL_NULL_HENV 0
88 # define SQL_NULL_HDBC 0
89 # define SQL_NULL_HSTMT 0