1 /** 2 * Windows API header module 3 * 4 * Translated from MinGW Windows headers 5 * 6 * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost License 1.0) 7 * Source: $(PHOBOSSRC etc/c/odbc/_sqlext.d) 8 9 See_Also: $(LINK2 https://docs.microsoft.com/en-us/sql/odbc/reference/syntax/odbc-api-reference, 10 ODBC API Reference on MSDN) 11 */ 12 module etc.c.odbc.sqlext; 13 14 /* Conversion notes: 15 The MinGW file was a horrible mess. All of the #defines were sorted alphabetically, 16 which is crazy. This file needs a lot of work. 17 In MinGW, sqlext #includes sqlucode, but sqlucode #includes sqlext, 18 creating a circular dependency! 19 */ 20 21 public import etc.c.odbc.sql; 22 23 enum SQL_SPEC_MAJOR = 3; 24 enum SQL_SPEC_MINOR = 51; 25 const char[] SQL_SPEC_STRING = "03.51"; 26 enum SQL_ACCESS_MODE = 101; 27 enum SQL_ACTIVE_CONNECTIONS = 0; 28 enum SQL_ACTIVE_STATEMENTS = 1; 29 30 enum SQL_DATE = 9; 31 enum SQL_TIME = 10; 32 enum SQL_SIGNED_OFFSET = -20; 33 enum SQL_TINYINT = -6; 34 enum SQL_TIMESTAMP = 11; 35 enum SQL_UNSIGNED_OFFSET = -22; 36 37 enum SQL_ADD = 4; 38 enum SQL_ALL_EXCEPT_LIKE = 2; 39 40 enum SQL_API_ALL_FUNCTIONS = 0; 41 enum SQL_API_SQLCOLATTRIBUTES = 6; 42 enum SQL_API_SQLDRIVERCONNECT = 41; 43 enum SQL_API_SQLBROWSECONNECT = 55; 44 enum SQL_API_SQLCOLUMNPRIVILEGES = 56; 45 enum SQL_API_SQLDESCRIBEPARAM = 58; 46 enum SQL_API_SQLEXTENDEDFETCH = 59; 47 enum SQL_API_SQLFOREIGNKEYS = 60; 48 enum SQL_API_SQLMORERESULTS = 61; 49 enum SQL_API_SQLNATIVESQL = 62; 50 enum SQL_API_SQLNUMPARAMS = 63; 51 enum SQL_API_SQLPARAMOPTIONS = 64; 52 enum SQL_API_SQLPRIMARYKEYS = 65; 53 enum SQL_API_SQLPROCEDURECOLUMNS = 66; 54 enum SQL_API_SQLPROCEDURES = 67; 55 enum SQL_API_SQLSETPOS = 68; 56 enum SQL_API_SQLSETSCROLLOPTIONS = 69; 57 enum SQL_API_SQLTABLEPRIVILEGES = 70; 58 enum SQL_API_SQLDRIVERS = 71; 59 enum SQL_API_SQLBINDPARAMETER = 72; 60 enum SQL_API_LOADBYORDINAL = 199; 61 62 enum SQL_ASYNC_ENABLE = 4; 63 enum SQL_ASYNC_ENABLE_OFF = 0UL; 64 enum SQL_ASYNC_ENABLE_ON = 1UL; 65 enum SQL_ASYNC_ENABLE_DEFAULT = SQL_ASYNC_ENABLE_OFF; 66 67 enum SQL_ATTR_CONNECTION_DEAD = 1209; 68 enum SQL_ATTR_READONLY = 0; 69 enum SQL_ATTR_READWRITE_UNKNOWN = 2; 70 enum SQL_ATTR_WRITE = 1; 71 72 enum SQL_AUTOCOMMIT = 102; 73 enum SQL_AUTOCOMMIT_OFF = 0UL; 74 enum SQL_AUTOCOMMIT_ON = 1UL; 75 enum SQL_AUTOCOMMIT_DEFAULT = SQL_AUTOCOMMIT_ON; 76 enum SQL_BEST_ROWID = 1; 77 enum SQL_BIGINT = -5; 78 enum SQL_BINARY = -2; 79 enum SQL_BIND_BY_COLUMN = 0UL; 80 enum SQL_BIND_TYPE = 5; 81 enum SQL_BIND_TYPE_DEFAULT = SQL_BIND_BY_COLUMN; 82 enum SQL_BIT = -7; 83 84 enum SQL_BOOKMARK_PERSISTENCE = 82; 85 86 // for BOOKMARK_PERSISTENCE 87 enum SQL_BP_CLOSE = 1; 88 enum SQL_BP_DELETE = 2; 89 enum SQL_BP_DROP = 4; 90 enum SQL_BP_TRANSACTION = 8; 91 enum SQL_BP_UPDATE = 16; 92 enum SQL_BP_OTHER_HSTMT = 32; 93 enum SQL_BP_SCROLL = 64; 94 95 enum SQL_C_BINARY = SQL_BINARY; 96 enum SQL_C_BIT = SQL_BIT; 97 enum SQL_C_CHAR = SQL_CHAR; 98 enum SQL_C_DATE = SQL_DATE; 99 enum SQL_C_DOUBLE = SQL_DOUBLE; 100 enum SQL_C_FLOAT = SQL_REAL; 101 enum SQL_C_LONG = SQL_INTEGER; 102 enum SQL_C_SHORT = SQL_SMALLINT; 103 enum SQL_C_SLONG = SQL_C_LONG+SQL_SIGNED_OFFSET; 104 enum SQL_C_SSHORT = SQL_C_SHORT+SQL_SIGNED_OFFSET; 105 enum SQL_C_STINYINT = SQL_TINYINT+SQL_SIGNED_OFFSET; 106 enum SQL_C_TIME = SQL_TIME; 107 enum SQL_C_TIMESTAMP = SQL_TIMESTAMP; 108 enum SQL_C_TINYINT = SQL_TINYINT; 109 enum SQL_C_ULONG = SQL_C_LONG+SQL_UNSIGNED_OFFSET; 110 enum SQL_C_USHORT = SQL_C_SHORT+SQL_UNSIGNED_OFFSET; 111 enum SQL_C_UTINYINT = SQL_TINYINT+SQL_UNSIGNED_OFFSET; 112 enum SQL_C_BOOKMARK = SQL_C_ULONG; 113 enum SQL_C_DEFAULT = 99; 114 115 enum SQL_CASCADE = 0; 116 enum SQL_CB_NON_NULL = 1; 117 enum SQL_CB_NULL = 0; 118 deprecated { 119 enum SQL_CC_CLOSE = SQL_CB_CLOSE;/* deprecated */ 120 enum SQL_CC_DELETE = SQL_CB_DELETE;/* deprecated */ 121 enum SQL_CC_PRESERVE = SQL_CB_PRESERVE;/* deprecated */ 122 } 123 enum SQL_CD_FALSE = 0L; 124 enum SQL_CD_TRUE = 1L; 125 126 enum SQL_CN_ANY = 2; 127 enum SQL_CN_DIFFERENT = 1; 128 enum SQL_CN_NONE = 0; 129 130 enum SQL_COLUMN_ALIAS = 87; 131 132 enum SQL_COLUMN_COUNT = 0; 133 enum SQL_COLUMN_NAME = 1; 134 enum SQL_COLUMN_DISPLAY_SIZE = 6; 135 enum SQL_COLUMN_LABEL = 18; 136 enum SQL_COLUMN_LENGTH = 3; 137 enum SQL_COLUMN_MONEY = 9; 138 enum SQL_COLUMN_NULLABLE = 7; 139 enum SQL_COLUMN_OWNER_NAME = 16; 140 enum SQL_COLUMN_PRECISION = 4; 141 enum SQL_COLUMN_QUALIFIER_NAME = 17; 142 enum SQL_COLUMN_SCALE = 5; 143 enum SQL_COLUMN_UNSIGNED = 8; 144 enum SQL_COLUMN_UPDATABLE = 10; 145 enum SQL_COLUMN_AUTO_INCREMENT = 11; 146 enum SQL_COLUMN_CASE_SENSITIVE = 12; 147 enum SQL_COLUMN_SEARCHABLE = 13; 148 enum SQL_COLUMN_TYPE = 2; 149 enum SQL_COLUMN_TYPE_NAME = 14; 150 enum SQL_COLUMN_TABLE_NAME = 15; 151 152 enum SQL_CONCAT_NULL_BEHAVIOR = 22; 153 154 enum SQL_CONCUR_READ_ONLY = 1; 155 enum SQL_CONCUR_DEFAULT = SQL_CONCUR_READ_ONLY; 156 enum SQL_CONCUR_LOCK = 2; 157 enum SQL_CONCUR_ROWVER = 3; 158 enum SQL_CONCUR_TIMESTAMP = SQL_CONCUR_ROWVER;/* deprecated */ 159 enum SQL_CONCUR_VALUES = 4; 160 161 enum SQL_CONCURRENCY = 7; 162 enum SQL_CONVERT_BIGINT = 53; 163 enum SQL_CONVERT_BINARY = 54; 164 enum SQL_CONVERT_BIT = 55; 165 enum SQL_CONVERT_CHAR = 56; 166 enum SQL_CONVERT_DATE = 57; 167 enum SQL_CONVERT_DECIMAL = 58; 168 enum SQL_CONVERT_DOUBLE = 59; 169 enum SQL_CONVERT_FLOAT = 60; 170 enum SQL_CONVERT_FUNCTIONS = 48; 171 enum SQL_CONVERT_INTEGER = 61; 172 enum SQL_CONVERT_LONGVARBINARY = 71; 173 enum SQL_CONVERT_LONGVARCHAR = 62; 174 enum SQL_CONVERT_NUMERIC = 63; 175 enum SQL_CONVERT_REAL = 64; 176 enum SQL_CONVERT_SMALLINT = 65; 177 enum SQL_CONVERT_TIME = 66; 178 enum SQL_CONVERT_TIMESTAMP = 67; 179 enum SQL_CONVERT_TINYINT = 68; 180 enum SQL_CONVERT_VARBINARY = 69; 181 enum SQL_CONVERT_VARCHAR = 70; 182 enum SQL_CORRELATION_NAME = 74; 183 enum SQL_CR_CLOSE = SQL_CB_CLOSE;/* deprecated */ 184 enum SQL_CR_DELETE = SQL_CB_DELETE;/* deprecated */ 185 enum SQL_CR_PRESERVE = SQL_CB_PRESERVE;/* deprecated */ 186 187 enum : ULONG { 188 SQL_CUR_USE_IF_NEEDED = 0, 189 SQL_CUR_USE_ODBC, 190 SQL_CUR_USE_DRIVER, 191 SQL_CUR_DEFAULT = SQL_CUR_USE_DRIVER 192 } 193 194 enum SQL_CURRENT_QUALIFIER = 109; 195 enum SQL_CURSOR_DYNAMIC = 2UL; 196 enum SQL_CURSOR_FORWARD_ONLY = 0UL; 197 enum SQL_CURSOR_KEYSET_DRIVEN = 1UL; 198 enum SQL_CURSOR_ROLLBACK_BEHAVIOR = 24; 199 enum SQL_CURSOR_STATIC = 3UL; 200 enum SQL_CURSOR_TYPE = 6; 201 enum SQL_CURSOR_TYPE_DEFAULT = SQL_CURSOR_FORWARD_ONLY; 202 203 enum SQL_CV_CASCADED = 0x00000004L; 204 enum SQL_CV_CHECK_OPTION = 0x00000002L; 205 enum SQL_CV_CREATE_VIEW = 0x00000001L; 206 enum SQL_CV_LOCAL = 0x00000008L; 207 enum SQL_CVT_BIGINT = 0x00004000L; 208 enum SQL_CVT_BINARY = 0x00000400L; 209 enum SQL_CVT_BIT = 0x00001000L; 210 enum SQL_CVT_CHAR = 0x00000001L; 211 enum SQL_CVT_DATE = 0x00008000L; 212 enum SQL_CVT_DECIMAL = 0x00000004L; 213 enum SQL_CVT_DOUBLE = 0x00000080L; 214 enum SQL_CVT_FLOAT = 0x00000020L; 215 enum SQL_CVT_INTEGER = 0x00000008L; 216 enum SQL_CVT_LONGVARBINARY = 0x00040000L; 217 enum SQL_CVT_LONGVARCHAR = 0x00000200L; 218 enum SQL_CVT_NUMERIC = 0x00000002L; 219 enum SQL_CVT_REAL = 0x00000040L; 220 enum SQL_CVT_SMALLINT = 0x00000010L; 221 enum SQL_CVT_TIME = 0x00010000L; 222 enum SQL_CVT_TIMESTAMP = 0x00020000L; 223 enum SQL_CVT_TINYINT = 0x00002000L; 224 enum SQL_CVT_VARBINARY = 0x00000800L; 225 enum SQL_CVT_VARCHAR = 0x00000100L; 226 enum SQL_DATABASE_NAME = 16;/* deprecated */ 227 228 enum SQL_DEFAULT_PARAM = -5; 229 enum SQL_DELETE = 3; 230 231 enum SQL_DRIVER_COMPLETE = 1; 232 enum SQL_DRIVER_COMPLETE_REQUIRED = 3; 233 enum SQL_DRIVER_HDBC = 3; 234 enum SQL_DRIVER_HENV = 4; 235 enum SQL_DRIVER_HLIB = 76; 236 enum SQL_DRIVER_HSTMT = 5; 237 enum SQL_DRIVER_NAME = 6; 238 enum SQL_DRIVER_NOPROMPT = 0; 239 enum SQL_DRIVER_ODBC_VER = 77; 240 enum SQL_DRIVER_PROMPT = 2; 241 enum SQL_DRIVER_VER = 7; 242 243 enum SQL_DTC_ENLIST_EXPENSIVE = 1; 244 enum SQL_DTC_UNENLIST_EXPENSIVE = 2; 245 enum SQL_DTC_TRANSITION_COST = 1750; 246 enum SQL_ENSURE = 1; 247 enum SQL_ENTIRE_ROWSET = 0; 248 enum SQL_EXPRESSIONS_IN_ORDERBY = 27; 249 enum SQL_FD_FETCH_BOOKMARK = 128; 250 enum SQL_FD_FETCH_PREV = SQL_FD_FETCH_PRIOR;/* deprecated */ 251 enum SQL_FD_FETCH_RESUME = 64; 252 enum SQL_FETCH_BOOKMARK = 8; 253 enum SQL_FETCH_PREV = SQL_FETCH_PRIOR;/* deprecated */ 254 enum SQL_FETCH_RESUME = 7;/* deprecated */ 255 256 enum SQL_FILE_NOT_SUPPORTED = 0x0000; 257 enum SQL_FILE_TABLE = 0x0001; 258 enum SQL_FILE_QUALIFIER = 0x0002; 259 enum SQL_FILE_CATALOG = SQL_FILE_QUALIFIER; 260 enum SQL_FILE_USAGE = 84; 261 262 enum SQL_FN_CVT_CONVERT = 0x00000001L; 263 enum SQL_FN_NUM_ABS = 0x00000001L; 264 enum SQL_FN_NUM_ACOS = 0x00000002L; 265 enum SQL_FN_NUM_ASIN = 0x00000004L; 266 enum SQL_FN_NUM_ATAN = 0x00000008L; 267 enum SQL_FN_NUM_ATAN2 = 0x00000010L; 268 enum SQL_FN_NUM_CEILING = 0x00000020L; 269 enum SQL_FN_NUM_COS = 0x00000040L; 270 enum SQL_FN_NUM_COT = 0x00000080L; 271 enum SQL_FN_NUM_DEGREES = 0x00040000L; 272 enum SQL_FN_NUM_EXP = 0x00000100L; 273 enum SQL_FN_NUM_FLOOR = 0x00000200L; 274 enum SQL_FN_NUM_LOG = 0x00000400L; 275 enum SQL_FN_NUM_LOG10 = 0x00080000L; 276 enum SQL_FN_NUM_MOD = 0x00000800L; 277 enum SQL_FN_NUM_PI = 0x00010000L; 278 enum SQL_FN_NUM_POWER = 0x00100000L; 279 enum SQL_FN_NUM_RADIANS = 0x00200000L; 280 enum SQL_FN_NUM_RAND = 0x00020000L; 281 enum SQL_FN_NUM_ROUND = 0x00400000L; 282 enum SQL_FN_NUM_SIGN = 0x00001000L; 283 enum SQL_FN_NUM_SIN = 0x00002000L; 284 enum SQL_FN_NUM_SQRT = 0x00004000L; 285 enum SQL_FN_NUM_TAN = 0x00008000L; 286 enum SQL_FN_NUM_TRUNCATE = 0x00800000L; 287 enum SQL_FN_STR_ASCII = 0x00002000L; 288 enum SQL_FN_STR_CHAR = 0x00004000L; 289 enum SQL_FN_STR_CONCAT = 0x00000001L; 290 enum SQL_FN_STR_DIFFERENCE = 0x00008000L; 291 enum SQL_FN_STR_INSERT = 0x00000002L; 292 enum SQL_FN_STR_LCASE = 0x00000040L; 293 enum SQL_FN_STR_LEFT = 0x00000004L; 294 enum SQL_FN_STR_LENGTH = 0x00000010L; 295 enum SQL_FN_STR_LOCATE = 0x00000020L; 296 enum SQL_FN_STR_LOCATE_2 = 0x00010000L; 297 enum SQL_FN_STR_LTRIM = 0x00000008L; 298 enum SQL_FN_STR_REPEAT = 0x00000080L; 299 enum SQL_FN_STR_REPLACE = 0x00000100L; 300 enum SQL_FN_STR_RIGHT = 0x00000200L; 301 enum SQL_FN_STR_RTRIM = 0x00000400L; 302 enum SQL_FN_STR_SOUNDEX = 0x00020000L; 303 enum SQL_FN_STR_SPACE = 0x00040000L; 304 enum SQL_FN_STR_SUBSTRING = 0x00000800L; 305 enum SQL_FN_STR_UCASE = 0x00001000L; 306 enum SQL_FN_SYS_DBNAME = 0x00000002L; 307 enum SQL_FN_SYS_IFNULL = 0x00000004L; 308 enum SQL_FN_SYS_USERNAME = 0x00000001L; 309 enum SQL_FN_TD_CURDATE = 0x00000002L; 310 enum SQL_FN_TD_CURTIME = 0x00000200L; 311 enum SQL_FN_TD_DAYNAME = 0x00008000L; 312 enum SQL_FN_TD_DAYOFMONTH = 0x00000004L; 313 enum SQL_FN_TD_DAYOFWEEK = 0x00000008L; 314 enum SQL_FN_TD_DAYOFYEAR = 0x00000010L; 315 enum SQL_FN_TD_HOUR = 0x00000400L; 316 enum SQL_FN_TD_MINUTE = 0x00000800L; 317 enum SQL_FN_TD_MONTH = 0x00000020L; 318 enum SQL_FN_TD_MONTHNAME = 0x00010000L; 319 enum SQL_FN_TD_NOW = 0x00000001L; 320 enum SQL_FN_TD_QUARTER = 0x00000040L; 321 enum SQL_FN_TD_SECOND = 0x00001000L; 322 enum SQL_FN_TD_TIMESTAMPADD = 0x00002000L; 323 enum SQL_FN_TD_TIMESTAMPDIFF = 0x00004000L; 324 enum SQL_FN_TD_WEEK = 0x00000080L; 325 enum SQL_FN_TD_YEAR = 0x00000100L; 326 enum SQL_FN_TSI_DAY = 0x00000010L; 327 enum SQL_FN_TSI_FRAC_SECOND = 0x00000001L; 328 enum SQL_FN_TSI_HOUR = 0x00000008L; 329 enum SQL_FN_TSI_MINUTE = 0x00000004L; 330 enum SQL_FN_TSI_MONTH = 0x00000040L; 331 enum SQL_FN_TSI_QUARTER = 0x00000080L; 332 enum SQL_FN_TSI_SECOND = 0x00000002L; 333 enum SQL_FN_TSI_WEEK = 0x00000020L; 334 enum SQL_FN_TSI_YEAR = 0x00000100L; 335 enum SQL_GB_GROUP_BY_CONTAINS_SELECT = 2; 336 enum SQL_GB_GROUP_BY_EQUALS_SELECT = 1; 337 enum SQL_GB_NO_RELATION = 3; 338 enum SQL_GB_NOT_SUPPORTED = 0; 339 enum SQL_GD_BLOCK = 4; 340 enum SQL_GD_BOUND = 8; 341 enum SQL_GET_BOOKMARK = 13; 342 enum SQL_GROUP_BY = 88; 343 enum SQL_IGNORE = -6; 344 enum SQL_INFO_FIRST = 0; 345 enum SQL_KEYSET_SIZE = 8; 346 enum SQL_KEYSET_SIZE_DEFAULT = 0UL; 347 enum SQL_KEYWORDS = 89; 348 enum SQL_LCK_EXCLUSIVE = 2; 349 enum SQL_LCK_NO_CHANGE = 1; 350 enum SQL_LCK_UNLOCK = 4; 351 352 enum SQL_LEN_BINARY_ATTR_OFFSET = -100; 353 enum SQL_LEN_DATA_AT_EXEC_OFFSET = -100; 354 //MACRO #define SQL_LEN_BINARY_ATTR(length) (-(length)+SQL_LEN_BINARY_ATTR_OFFSET) 355 //MACRO #define SQL_LEN_DATA_AT_EXEC(length) (-(length)+SQL_LEN_DATA_AT_EXEC_OFFSET) 356 357 enum SQL_LIKE_ESCAPE_CLAUSE = 113; 358 enum SQL_LIKE_ONLY = 1; 359 enum SQL_LOCK_EXCLUSIVE = 1; 360 enum SQL_LOCK_NO_CHANGE = 0; 361 enum SQL_LOCK_TYPES = 78; 362 enum SQL_LOCK_UNLOCK = 2; 363 enum SQL_LOGIN_TIMEOUT = 103; 364 enum SQL_LOGIN_TIMEOUT_DEFAULT = 15UL; 365 enum SQL_LONGVARBINARY = -4; 366 enum SQL_LONGVARCHAR = -1; 367 enum SQL_MAX_BINARY_LITERAL_LEN = 112; 368 enum SQL_MAX_CHAR_LITERAL_LEN = 108; 369 enum SQL_MAX_DSN_LENGTH = 32; 370 enum SQL_MAX_LENGTH = 3; 371 enum SQL_MAX_LENGTH_DEFAULT = 0UL; 372 enum SQL_MAX_OPTION_STRING_LENGTH = 256; 373 enum SQL_MAX_OWNER_NAME_LEN = 32; 374 enum SQL_MAX_PROCEDURE_NAME_LEN = 33; 375 enum SQL_MAX_QUALIFIER_NAME_LEN = 34; 376 enum SQL_MAX_ROW_SIZE_INCLUDES_LONG = 103; 377 enum SQL_MAX_ROWS = 1; 378 enum SQL_MAX_ROWS_DEFAULT = 0UL; 379 380 enum SQL_MODE_READ_WRITE = 0UL; 381 enum SQL_MODE_READ_ONLY = 1UL; 382 enum SQL_MODE_DEFAULT = SQL_MODE_READ_WRITE; 383 384 enum SQL_MULT_RESULT_SETS = 36; 385 enum SQL_MULTIPLE_ACTIVE_TXN = 37; 386 enum SQL_NC_END = 0x0004; 387 enum SQL_NC_START = 0x0002; 388 enum SQL_NEED_LONG_DATA_LEN = 111; 389 enum SQL_NNC_NON_NULL = 0x0001; 390 enum SQL_NNC_NULL = 0x0000; 391 enum SQL_NO_TOTAL = -4; 392 enum SQL_NON_NULLABLE_COLUMNS = 75; 393 394 enum SQL_NOSCAN_OFF = 0UL; 395 enum SQL_NOSCAN_ON = 1UL; 396 enum SQL_NOSCAN = 2; 397 enum SQL_NOSCAN_DEFAULT = SQL_NOSCAN_OFF; 398 399 enum SQL_NUMERIC_FUNCTIONS = 49; 400 enum SQL_OAC_LEVEL1 = 0x0001; 401 enum SQL_OAC_LEVEL2 = 0x0002; 402 enum SQL_OAC_NONE = 0x0000; 403 enum SQL_ODBC_API_CONFORMANCE = 9; 404 enum SQL_ODBC_CURSORS = 110; 405 enum SQL_ODBC_SAG_CLI_CONFORMANCE = 12; 406 enum SQL_ODBC_SQL_CONFORMANCE = 15; 407 enum SQL_ODBC_SQL_OPT_IEF = 73; 408 enum SQL_ODBC_VER = 10; 409 enum SQL_OPT_TRACE = 104; 410 411 enum SQL_OPT_TRACE_FILE_DEFAULT = "\\SQL.LOG"; 412 enum SQL_OPT_TRACE_OFF = 0UL; 413 enum SQL_OPT_TRACE_DEFAULT = SQL_OPT_TRACE_OFF; 414 enum SQL_OPT_TRACE_ON = 1UL; 415 416 enum SQL_OPT_TRACEFILE = 105; 417 enum SQL_OSC_CORE = 1; 418 enum SQL_OSC_EXTENDED = 2; 419 enum SQL_OSC_MINIMUM = 0; 420 enum SQL_OSCC_COMPLIANT = 1; 421 enum SQL_OSCC_NOT_COMPLIANT = 0; 422 enum SQL_OU_DML_STATEMENTS = 1; 423 enum SQL_OU_INDEX_DEFINITION = 8; 424 enum SQL_OU_PRIVILEGE_DEFINITION = 16; 425 enum SQL_OU_PROCEDURE_INVOCATION = 2; 426 enum SQL_OU_TABLE_DEFINITION = 4; 427 enum SQL_OUTER_JOINS = 38; 428 enum SQL_OWNER_TERM = 39; 429 enum SQL_OWNER_USAGE = 91; 430 enum SQL_PACKET_SIZE = 112; 431 enum SQL_PARAM_INPUT = 1; 432 enum SQL_PARAM_INPUT_OUTPUT = 2; 433 enum SQL_PARAM_OUTPUT = 4; 434 enum SQL_PARAM_TYPE_DEFAULT = SQL_PARAM_INPUT_OUTPUT; 435 enum SQL_PARAM_TYPE_UNKNOWN = 0; 436 enum SQL_PC_NOT_PSEUDO = 1; 437 enum SQL_POS_ADD = 16; 438 enum SQL_POS_DELETE = 8; 439 enum SQL_POS_OPERATIONS = 79; 440 enum SQL_POS_POSITION = 1; 441 enum SQL_POS_REFRESH = 2; 442 enum SQL_POS_UPDATE = 4; 443 enum SQL_POSITION = 0; 444 enum SQL_POSITIONED_STATEMENTS = 80; 445 enum SQL_PROCEDURE_TERM = 40; 446 enum SQL_PROCEDURES = 21; 447 enum SQL_PS_POSITIONED_DELETE = 1; 448 enum SQL_PS_POSITIONED_UPDATE = 2; 449 enum SQL_PS_SELECT_FOR_UPDATE = 4; 450 enum SQL_PT_FUNCTION = 2; 451 enum SQL_PT_PROCEDURE = 1; 452 enum SQL_PT_UNKNOWN = 0; 453 enum SQL_QL_END = 0x0002; 454 enum SQL_QL_START = 0x0001; 455 enum SQL_QU_DML_STATEMENTS = 1; 456 enum SQL_QU_INDEX_DEFINITION = 8; 457 enum SQL_QU_PRIVILEGE_DEFINITION = 16; 458 enum SQL_QU_PROCEDURE_INVOCATION = 2; 459 enum SQL_QU_TABLE_DEFINITION = 4; 460 enum SQL_QUALIFIER_LOCATION = 114; 461 enum SQL_QUALIFIER_NAME_SEPARATOR = 41; 462 enum SQL_QUALIFIER_TERM = 42; 463 enum SQL_QUALIFIER_USAGE = 92; 464 enum SQL_QUERY_TIMEOUT = 0; 465 enum SQL_QUERY_TIMEOUT_DEFAULT = 0UL; 466 enum SQL_QUICK = 0; 467 enum SQL_QUIET_MODE = 111; 468 enum SQL_QUOTED_IDENTIFIER_CASE = 93; 469 470 enum SQL_RD_OFF = 0UL; 471 enum SQL_RD_ON = 1UL; 472 enum SQL_RD_DEFAULT = SQL_RD_ON; 473 474 enum SQL_REFRESH = 1; 475 enum SQL_RESTRICT = 1; 476 enum SQL_RESULT_COL = 3; 477 enum SQL_RETRIEVE_DATA = 11; 478 enum SQL_RETURN_VALUE = 5; 479 enum SQL_ROW_ADDED = 4; 480 enum SQL_ROW_DELETED = 1; 481 enum SQL_ROW_ERROR = 5; 482 enum SQL_ROW_NOROW = 3; 483 enum SQL_ROW_NUMBER = 14; 484 enum SQL_ROW_SUCCESS = 0; 485 enum SQL_ROW_UPDATED = 2; 486 enum SQL_ROW_UPDATES = 11; 487 enum SQL_ROWSET_SIZE = 9; 488 enum SQL_ROWSET_SIZE_DEFAULT = 1UL; 489 enum SQL_ROWVER = 2; 490 enum SQL_SC_NON_UNIQUE = 0UL; 491 enum SQL_SC_TRY_UNIQUE = 1UL; 492 enum SQL_SC_UNIQUE = 2UL; 493 enum SQL_SCCO_OPT_TIMESTAMP = SQL_SCCO_OPT_ROWVER;/* deprecated */ 494 enum SQL_SCROLL_DYNAMIC = -2L;/* deprecated */ 495 enum SQL_SCROLL_FORWARD_ONLY = 0L;/* deprecated */ 496 enum SQL_SCROLL_KEYSET_DRIVEN = -1L;/* deprecated */ 497 enum SQL_SCROLL_OPTIONS = 44; 498 enum SQL_SCROLL_STATIC = -3L;/* deprecated */ 499 enum SQL_SEARCHABLE = 3; 500 enum SQL_SET_NULL = 2; 501 enum SQL_SETPARAM_VALUE_MAX = -1L; 502 enum SQL_SETPOS_MAX_LOCK_VALUE = SQL_LOCK_UNLOCK; 503 enum SQL_SETPOS_MAX_OPTION_VALUE = SQL_ADD; 504 enum SQL_SIMULATE_CURSOR = 10; 505 enum SQL_SO_DYNAMIC = 4; 506 enum SQL_SO_FORWARD_ONLY = 1; 507 enum SQL_SO_KEYSET_DRIVEN = 2; 508 enum SQL_SO_MIXED = 8; 509 enum SQL_SO_STATIC = 16; 510 enum SQL_SQ_COMPARISON = 1; 511 enum SQL_SQ_CORRELATED_SUBQUERIES = 16; 512 enum SQL_SQ_EXISTS = 2; 513 enum SQL_SQ_IN = 4; 514 enum SQL_SQ_QUANTIFIED = 8; 515 enum SQL_SQLSTATE_SIZE = 5; 516 enum SQL_SS_ADDITIONS = 1; 517 enum SQL_SS_DELETIONS = 2; 518 enum SQL_SS_UPDATES = 4; 519 enum SQL_STATIC_SENSITIVITY = 83; 520 enum SQL_STRING_FUNCTIONS = 50; 521 enum SQL_SUBQUERIES = 95; 522 enum SQL_SYSTEM_FUNCTIONS = 51; 523 enum SQL_TABLE_STAT = 0; 524 enum SQL_TABLE_TERM = 45; 525 enum SQL_TIMEDATE_ADD_INTERVALS = 109; 526 enum SQL_TIMEDATE_DIFF_INTERVALS = 110; 527 enum SQL_TIMEDATE_FUNCTIONS = 52; 528 enum SQL_TRANSLATE_DLL = 106; 529 enum SQL_TRANSLATE_OPTION = 107; 530 enum SQL_TXN_ISOLATION = 108; 531 enum SQL_TXN_VERSIONING = 16; 532 enum SQL_TYPE_NULL = 0; 533 enum SQL_U_UNION = 1; 534 enum SQL_U_UNION_ALL = 2; 535 536 enum SQL_UB_OFF = 0UL; 537 enum SQL_UB_DEFAULT = SQL_UB_OFF; 538 enum SQL_UB_ON = 1UL; 539 540 enum SQL_UNION = 96; 541 enum SQL_UNSEARCHABLE = 0; 542 enum SQL_UPDATE = 2; 543 enum SQL_USE_BOOKMARKS = 12; 544 enum SQL_VARBINARY = -3; 545 546 enum SQL_COLATT_OPT_MAX = SQL_COLUMN_LABEL; 547 enum SQL_COLATT_OPT_MIN = SQL_COLUMN_COUNT; 548 enum SQL_PRED_SEARCHABLE = SQL_SEARCHABLE; 549 550 //MACRO #define SQL_POSITION_TO(s, r) SQLSetPos(s, r, SQL_POSITION, SQL_LOCK_NO_CHANGE) 551 552 //MACRO #define SQL_LOCK_RECORD(s, r, l) SQLSetPos(s, r, SQL_POSITION, l) 553 554 //MACRO #define SQL_REFRESH_RECORD(s, r, l) SQLSetPos(s, r, SQL_REFRESH, l) 555 556 //MACRO #define SQL_UPDATE_RECORD(s, r) SQLSetPos(s, r, SQL_UPDATE, SQL_LOCK_NO_CHANGE) 557 558 //MACRO #define SQL_DELETE_RECORD(s, r) SQLSetPos(s, r, SQL_DELETE, SQL_LOCK_NO_CHANGE) 559 560 //MACRO #define SQL_ADD_RECORD(s, r) SQLSetPos(s, r, SQL_ADD, SQL_LOCK_NO_CHANGE) 561 562 563 static if (ODBCVER < 0x0300) 564 { 565 enum SQL_CONNECT_OPT_DRVR_START = 1000; 566 enum SQL_CONN_OPT_MAX = SQL_PACKET_SIZE; 567 enum SQL_CONN_OPT_MIN = SQL_ACCESS_MODE; 568 enum SQL_STMT_OPT_MAX = SQL_ROW_NUMBER; 569 enum SQL_STMT_OPT_MIN = SQL_QUERY_TIMEOUT; 570 enum SQL_TYPE_DRIVER_START = SQL_INTERVAL_YEAR; 571 enum SQL_TYPE_DRIVER_END = SQL_UNICODE_LONGVARCHAR; 572 enum SQL_TYPE_MIN = SQL_BIT; 573 enum SQL_TYPE_MAX = SQL_VARCHAR; 574 } 575 576 static if (ODBCVER < 0x0300) 577 { 578 enum SQL_NO_DATA_FOUND = 100; 579 enum SQL_INTERVAL_YEAR = -80; 580 enum SQL_INTERVAL_MONTH = -81; 581 enum SQL_INTERVAL_YEAR_TO_MONTH = -82; 582 enum SQL_INTERVAL_DAY = -83; 583 enum SQL_INTERVAL_HOUR = -84; 584 enum SQL_INTERVAL_MINUTE = -85; 585 enum SQL_INTERVAL_SECOND = -86; 586 enum SQL_INTERVAL_DAY_TO_HOUR = -87; 587 enum SQL_INTERVAL_DAY_TO_MINUTE = -88; 588 enum SQL_INTERVAL_DAY_TO_SECOND = -89; 589 enum SQL_INTERVAL_HOUR_TO_MINUTE = -90; 590 enum SQL_INTERVAL_HOUR_TO_SECOND = -91; 591 enum SQL_INTERVAL_MINUTE_TO_SECOND = -92; 592 } 593 else 594 { 595 enum SQL_NO_DATA_FOUND = SQL_NO_DATA; 596 enum SQL_CODE_YEAR = 1; 597 enum SQL_CODE_MONTH = 2; 598 enum SQL_CODE_DAY = 3; 599 enum SQL_CODE_HOUR = 4; 600 enum SQL_CODE_MINUTE = 5; 601 enum SQL_CODE_SECOND = 6; 602 enum SQL_CODE_YEAR_TO_MONTH = 7; 603 enum SQL_CODE_DAY_TO_HOUR = 8; 604 enum SQL_CODE_DAY_TO_MINUTE = 9; 605 enum SQL_CODE_DAY_TO_SECOND = 10; 606 enum SQL_CODE_HOUR_TO_MINUTE = 11; 607 enum SQL_CODE_HOUR_TO_SECOND = 12; 608 enum SQL_CODE_MINUTE_TO_SECOND = 13; 609 enum SQL_INTERVAL_YEAR = 100 + SQL_CODE_YEAR; 610 enum SQL_INTERVAL_MONTH = 100 + SQL_CODE_MONTH; 611 enum SQL_INTERVAL_DAY = 100 + SQL_CODE_DAY; 612 enum SQL_INTERVAL_HOUR = 100 + SQL_CODE_HOUR; 613 enum SQL_INTERVAL_MINUTE = 100 + SQL_CODE_MINUTE; 614 enum SQL_INTERVAL_SECOND = 100 + SQL_CODE_SECOND; 615 enum SQL_INTERVAL_YEAR_TO_MONTH = 100 + SQL_CODE_YEAR_TO_MONTH; 616 enum SQL_INTERVAL_DAY_TO_HOUR = 100 + SQL_CODE_DAY_TO_HOUR; 617 enum SQL_INTERVAL_DAY_TO_MINUTE = 100 + SQL_CODE_DAY_TO_MINUTE; 618 enum SQL_INTERVAL_DAY_TO_SECOND = 100 + SQL_CODE_DAY_TO_SECOND; 619 enum SQL_INTERVAL_HOUR_TO_MINUTE = 100 + SQL_CODE_HOUR_TO_MINUTE; 620 enum SQL_INTERVAL_HOUR_TO_SECOND = 100 + SQL_CODE_HOUR_TO_SECOND; 621 enum SQL_INTERVAL_MINUTE_TO_SECOND = 100 + SQL_CODE_MINUTE_TO_SECOND; 622 }//[Yes] #endif 623 624 625 static if ((ODBCVER >= 0x0201) && (ODBCVER < 0x0300)) 626 { 627 enum SQL_OJ_CAPABILITIES = 65003; 628 } 629 630 static if (ODBCVER >= 0x0250) 631 { 632 enum SQL_NO_ACTION = 3; 633 enum SQL_SET_DEFAULT = 4; 634 } 635 636 static if (ODBCVER >= 0x0300) 637 { 638 enum SQL_ACTIVE_ENVIRONMENTS = 116; 639 enum SQL_AD_ADD_CONSTRAINT_DEFERRABLE = 0x00000080L; 640 enum SQL_AD_ADD_CONSTRAINT_INITIALLY_DEFERRED = 0x00000020L; 641 enum SQL_AD_ADD_CONSTRAINT_INITIALLY_IMMEDIATE = 0x00000040L; 642 enum SQL_AD_ADD_CONSTRAINT_NON_DEFERRABLE = 0x00000100L; 643 enum SQL_AD_ADD_DOMAIN_CONSTRAINT = 0x00000002L; 644 enum SQL_AD_ADD_DOMAIN_DEFAULT = 0x00000008L; 645 enum SQL_AD_CONSTRAINT_NAME_DEFINITION = 0x00000001L; 646 enum SQL_AD_DROP_DOMAIN_CONSTRAINT = 0x00000004L; 647 enum SQL_AD_DROP_DOMAIN_DEFAULT = 0x00000010L; 648 enum SQL_AF_ALL = 0x00000040L; 649 enum SQL_AF_AVG = 0x00000001L; 650 enum SQL_AF_COUNT = 0x00000002L; 651 enum SQL_AF_DISTINCT = 0x00000020L; 652 enum SQL_AF_MAX = 0x00000004L; 653 enum SQL_AF_MIN = 0x00000008L; 654 enum SQL_AF_SUM = 0x00000010L; 655 enum SQL_AGGREGATE_FUNCTIONS = 169; 656 enum SQL_ALL_CATALOGS = "%"; 657 enum SQL_ALL_SCHEMAS = "%"; 658 enum SQL_ALL_TABLE_TYPES = "%"; 659 enum SQL_ALTER_DOMAIN = 117; 660 enum SQL_AM_CONNECTION = 1; 661 enum SQL_AM_NONE = 0; 662 enum SQL_AM_STATEMENT = 2; 663 enum SQL_API_ODBC3_ALL_FUNCTIONS = 999; 664 enum SQL_API_ODBC3_ALL_FUNCTIONS_SIZE = 250; 665 enum SQL_API_SQLALLOCHANDLESTD = 73; 666 enum SQL_API_SQLBULKOPERATIONS = 24; 667 enum SQL_ASYNC_MODE = 10021; 668 enum SQL_AT_ADD_COLUMN_COLLATION = 0x00000080L; 669 enum SQL_AT_ADD_COLUMN_DEFAULT = 0x00000040L; 670 enum SQL_AT_ADD_COLUMN_SINGLE = 0x00000020L; 671 enum SQL_AT_ADD_TABLE_CONSTRAINT = 0x00001000L; 672 enum SQL_AT_CONSTRAINT_DEFERRABLE = 0x00040000L; 673 enum SQL_AT_CONSTRAINT_INITIALLY_DEFERRED = 0x00010000L; 674 enum SQL_AT_CONSTRAINT_INITIALLY_IMMEDIATE = 0x00020000L; 675 enum SQL_AT_CONSTRAINT_NAME_DEFINITION = 0x00008000L; 676 enum SQL_AT_CONSTRAINT_NON_DEFERRABLE = 0x00080000L; 677 enum SQL_AT_DROP_COLUMN_CASCADE = 0x00000400L; 678 enum SQL_AT_DROP_COLUMN_DEFAULT = 0x00000200L; 679 enum SQL_AT_DROP_COLUMN_RESTRICT = 0x00000800L; 680 enum SQL_AT_DROP_TABLE_CONSTRAINT_CASCADE = 0x00002000L; 681 enum SQL_AT_DROP_TABLE_CONSTRAINT_RESTRICT = 0x00004000L; 682 enum SQL_AT_SET_COLUMN_DEFAULT = 0x00000100L; 683 enum SQL_ATTR_ACCESS_MODE = SQL_ACCESS_MODE; 684 enum SQL_ATTR_ASYNC_ENABLE = 4; 685 enum SQL_ATTR_AUTOCOMMIT = SQL_AUTOCOMMIT; 686 enum SQL_ATTR_CONCURRENCY = SQL_CONCURRENCY; 687 enum SQL_ATTR_CONNECTION_POOLING = 201; 688 enum SQL_ATTR_CONNECTION_TIMEOUT = 113; 689 enum SQL_ATTR_CP_MATCH = 202; 690 enum SQL_ATTR_CURRENT_CATALOG = SQL_CURRENT_QUALIFIER; 691 enum SQL_ATTR_CURSOR_TYPE = SQL_CURSOR_TYPE; 692 enum SQL_ATTR_DISCONNECT_BEHAVIOR = 114; 693 enum SQL_ATTR_ENABLE_AUTO_IPD = 15; 694 enum SQL_ATTR_ENLIST_IN_DTC = 1207; 695 enum SQL_ATTR_ENLIST_IN_XA = 1208; 696 enum SQL_ATTR_FETCH_BOOKMARK_PTR = 16; 697 enum SQL_ATTR_KEYSET_SIZE = SQL_KEYSET_SIZE; 698 enum SQL_ATTR_LOGIN_TIMEOUT = SQL_LOGIN_TIMEOUT; 699 enum SQL_ATTR_MAX_LENGTH = SQL_MAX_LENGTH; 700 enum SQL_ATTR_MAX_ROWS = SQL_MAX_ROWS; 701 enum SQL_ATTR_NOSCAN = SQL_NOSCAN; 702 enum SQL_ATTR_ODBC_CURSORS = SQL_ODBC_CURSORS; 703 enum SQL_ATTR_ODBC_VERSION = 200; 704 enum SQL_ATTR_PACKET_SIZE = SQL_PACKET_SIZE; 705 enum SQL_ATTR_PARAM_BIND_OFFSET_PTR = 17; 706 enum SQL_ATTR_PARAM_BIND_TYPE = 18; 707 enum SQL_ATTR_PARAM_OPERATION_PTR = 19; 708 enum SQL_ATTR_PARAM_STATUS_PTR = 20; 709 enum SQL_ATTR_PARAMS_PROCESSED_PTR = 21; 710 enum SQL_ATTR_PARAMSET_SIZE = 22; 711 enum SQL_ATTR_QUERY_TIMEOUT = SQL_QUERY_TIMEOUT; 712 enum SQL_ATTR_QUIET_MODE = SQL_QUIET_MODE; 713 enum SQL_ATTR_RETRIEVE_DATA = SQL_RETRIEVE_DATA; 714 enum SQL_ATTR_ROW_ARRAY_SIZE = 27; 715 enum SQL_ATTR_ROW_BIND_OFFSET_PTR = 23; 716 enum SQL_ATTR_ROW_BIND_TYPE = SQL_BIND_TYPE; 717 enum SQL_ATTR_ROW_NUMBER = SQL_ROW_NUMBER; 718 enum SQL_ATTR_ROW_OPERATION_PTR = 24; 719 enum SQL_ATTR_ROW_STATUS_PTR = 25; 720 enum SQL_ATTR_ROWS_FETCHED_PTR = 26; 721 enum SQL_ATTR_SIMULATE_CURSOR = SQL_SIMULATE_CURSOR; 722 enum SQL_ATTR_TRACE = SQL_OPT_TRACE; 723 enum SQL_ATTR_TRACEFILE = SQL_OPT_TRACEFILE; 724 enum SQL_ATTR_TRANSLATE_LIB = SQL_TRANSLATE_DLL; 725 enum SQL_ATTR_TRANSLATE_OPTION = SQL_TRANSLATE_OPTION; 726 enum SQL_ATTR_TXN_ISOLATION = SQL_TXN_ISOLATION; 727 enum SQL_ATTR_USE_BOOKMARKS = SQL_USE_BOOKMARKS; 728 enum SQL_BATCH_ROW_COUNT = 120; 729 enum SQL_BATCH_SUPPORT = 121; 730 enum SQL_BRC_EXPLICIT = 0x0000002; 731 enum SQL_BRC_PROCEDURES = 0x0000001; 732 enum SQL_BRC_ROLLED_UP = 0x0000004; 733 enum SQL_BS_ROW_COUNT_EXPLICIT = 0x00000002L; 734 enum SQL_BS_ROW_COUNT_PROC = 0x00000008L; 735 enum SQL_BS_SELECT_EXPLICIT = 0x00000001L; 736 enum SQL_BS_SELECT_PROC = 0x00000004L; 737 enum SQL_C_INTERVAL_DAY = SQL_INTERVAL_DAY; 738 enum SQL_C_INTERVAL_DAY_TO_HOUR = SQL_INTERVAL_DAY_TO_HOUR; 739 enum SQL_C_INTERVAL_DAY_TO_MINUTE = SQL_INTERVAL_DAY_TO_MINUTE; 740 enum SQL_C_INTERVAL_DAY_TO_SECOND = SQL_INTERVAL_DAY_TO_SECOND; 741 enum SQL_C_INTERVAL_HOUR = SQL_INTERVAL_HOUR; 742 enum SQL_C_INTERVAL_HOUR_TO_MINUTE = SQL_INTERVAL_HOUR_TO_MINUTE; 743 enum SQL_C_INTERVAL_HOUR_TO_SECOND = SQL_INTERVAL_HOUR_TO_SECOND; 744 enum SQL_C_INTERVAL_MINUTE = SQL_INTERVAL_MINUTE; 745 enum SQL_C_INTERVAL_MINUTE_TO_SECOND = SQL_INTERVAL_MINUTE_TO_SECOND; 746 enum SQL_C_INTERVAL_MONTH = SQL_INTERVAL_MONTH; 747 enum SQL_C_INTERVAL_SECOND = SQL_INTERVAL_SECOND; 748 enum SQL_C_INTERVAL_YEAR = SQL_INTERVAL_YEAR; 749 enum SQL_C_INTERVAL_YEAR_TO_MONTH = SQL_INTERVAL_YEAR_TO_MONTH; 750 enum SQL_C_NUMERIC = SQL_NUMERIC; 751 enum SQL_C_SBIGINT = SQL_BIGINT+SQL_SIGNED_OFFSET; 752 enum SQL_C_TYPE_DATE = SQL_TYPE_DATE; 753 enum SQL_C_TYPE_TIME = SQL_TYPE_TIME; 754 enum SQL_C_TYPE_TIMESTAMP = SQL_TYPE_TIMESTAMP; 755 enum SQL_C_UBIGINT = SQL_BIGINT+SQL_UNSIGNED_OFFSET; 756 enum SQL_C_VARBOOKMARK = SQL_C_BINARY; 757 enum SQL_CA_CONSTRAINT_DEFERRABLE = 0x00000040L; 758 enum SQL_CA_CONSTRAINT_INITIALLY_DEFERRED = 0x00000010L; 759 enum SQL_CA_CONSTRAINT_INITIALLY_IMMEDIATE = 0x00000020L; 760 enum SQL_CA_CONSTRAINT_NON_DEFERRABLE = 0x00000080L; 761 enum SQL_CA_CREATE_ASSERTION = 0x00000001L; 762 enum SQL_CA1_ABSOLUTE = 0x00000002L; 763 enum SQL_CA1_BOOKMARK = 0x00000008L; 764 enum SQL_CA1_BULK_ADD = 0x00010000L; 765 enum SQL_CA1_BULK_DELETE_BY_BOOKMARK = 0x00040000L; 766 enum SQL_CA1_BULK_FETCH_BY_BOOKMARK = 0x00080000L; 767 enum SQL_CA1_BULK_UPDATE_BY_BOOKMARK = 0x00020000L; 768 enum SQL_CA1_LOCK_EXCLUSIVE = 0x00000080L; 769 enum SQL_CA1_LOCK_NO_CHANGE = 0x00000040L; 770 enum SQL_CA1_LOCK_UNLOCK = 0x00000100L; 771 enum SQL_CA1_NEXT = 0x00000001L; 772 enum SQL_CA1_POS_DELETE = 0x00000800L; 773 enum SQL_CA1_POS_POSITION = 0x00000200L; 774 enum SQL_CA1_POS_REFRESH = 0x00001000L; 775 enum SQL_CA1_POS_UPDATE = 0x00000400L; 776 enum SQL_CA1_POSITIONED_DELETE = 0x00004000L; 777 enum SQL_CA1_POSITIONED_UPDATE = 0x00002000L; 778 enum SQL_CA1_RELATIVE = 0x00000004L; 779 enum SQL_CA1_SELECT_FOR_UPDATE = 0x00008000L; 780 enum SQL_CA2_CRC_APPROXIMATE = 0x00002000L; 781 enum SQL_CA2_CRC_EXACT = 0x00001000L; 782 enum SQL_CA2_LOCK_CONCURRENCY = 0x00000002L; 783 784 enum SQL_CA2_MAX_ROWS_CATALOG = 0x00000800L; 785 enum SQL_CA2_MAX_ROWS_DELETE = 0x00000200L; 786 enum SQL_CA2_MAX_ROWS_INSERT = 0x00000100L; 787 enum SQL_CA2_MAX_ROWS_SELECT = 0x00000080L; 788 enum SQL_CA2_MAX_ROWS_UPDATE = 0x00000400L; 789 enum SQL_CA2_MAX_ROWS_AFFECTS_ALL = SQL_CA2_MAX_ROWS_SELECT | SQL_CA2_MAX_ROWS_INSERT | 790 SQL_CA2_MAX_ROWS_DELETE | SQL_CA2_MAX_ROWS_UPDATE | SQL_CA2_MAX_ROWS_CATALOG; 791 792 enum SQL_CA2_OPT_ROWVER_CONCURRENCY = 0x00000004L; 793 enum SQL_CA2_OPT_VALUES_CONCURRENCY = 0x00000008L; 794 enum SQL_CA2_READ_ONLY_CONCURRENCY = 0x00000001L; 795 enum SQL_CA2_SENSITIVITY_ADDITIONS = 0x00000010L; 796 enum SQL_CA2_SENSITIVITY_DELETIONS = 0x00000020L; 797 enum SQL_CA2_SENSITIVITY_UPDATES = 0x00000040L; 798 enum SQL_CA2_SIMULATE_NON_UNIQUE = 0x00004000L; 799 enum SQL_CA2_SIMULATE_TRY_UNIQUE = 0x00008000L; 800 enum SQL_CA2_SIMULATE_UNIQUE = 0x00010000L; 801 enum SQL_CATALOG_LOCATION = SQL_QUALIFIER_LOCATION; 802 enum SQL_CATALOG_NAME_SEPARATOR = SQL_QUALIFIER_NAME_SEPARATOR; 803 enum SQL_CATALOG_TERM = SQL_QUALIFIER_TERM; 804 enum SQL_CATALOG_USAGE = SQL_QUALIFIER_USAGE; 805 enum SQL_CCOL_CREATE_COLLATION = 0x00000001L; 806 enum SQL_CCS_COLLATE_CLAUSE = 0x00000002L; 807 enum SQL_CCS_CREATE_CHARACTER_SET = 0x00000001L; 808 enum SQL_CCS_LIMITED_COLLATION = 0x00000004L; 809 enum SQL_CDO_COLLATION = 0x00000008L; 810 enum SQL_CDO_CONSTRAINT = 0x00000004L; 811 enum SQL_CDO_CONSTRAINT_DEFERRABLE = 0x00000080L; 812 enum SQL_CDO_CONSTRAINT_INITIALLY_DEFERRED = 0x00000020L; 813 enum SQL_CDO_CONSTRAINT_INITIALLY_IMMEDIATE = 0x00000040L; 814 enum SQL_CDO_CONSTRAINT_NAME_DEFINITION = 0x00000010L; 815 enum SQL_CDO_CONSTRAINT_NON_DEFERRABLE = 0x00000100L; 816 enum SQL_CDO_CREATE_DOMAIN = 0x00000001L; 817 enum SQL_CDO_DEFAULT = 0x00000002L; 818 enum SQL_CL_END = SQL_QL_END; 819 enum SQL_CL_START = SQL_QL_START; 820 enum SQL_COL_PRED_BASIC = SQL_ALL_EXCEPT_LIKE; 821 enum SQL_COL_PRED_CHAR = SQL_LIKE_ONLY; 822 enum SQL_COLUMN_DRIVER_START = 1000; 823 enum SQL_COLUMN_IGNORE = SQL_IGNORE; 824 enum SQL_COLUMN_NUMBER_UNKNOWN = -2; 825 enum SQL_CONVERT_GUID = 173; 826 827 enum SQL_CONVERT_WCHAR = 122; 828 enum SQL_CONVERT_INTERVAL_DAY_TIME = 123; 829 enum SQL_CONVERT_INTERVAL_YEAR_MONTH = 124; 830 enum SQL_CONVERT_WLONGVARCHAR = 125; 831 enum SQL_CONVERT_WVARCHAR = 126; 832 833 enum SQL_CREATE_ASSERTION = 127; 834 enum SQL_CREATE_CHARACTER_SET = 128; 835 enum SQL_CREATE_COLLATION = 129; 836 enum SQL_CREATE_DOMAIN = 130; 837 enum SQL_CREATE_SCHEMA = 131; 838 enum SQL_CREATE_TABLE = 132; 839 enum SQL_CREATE_TRANSLATION = 133; 840 enum SQL_CREATE_VIEW = 134; 841 842 843 enum SQL_CP_OFF = 0UL; 844 enum SQL_CP_DEFAULT = SQL_CP_OFF; 845 enum SQL_CP_ONE_PER_DRIVER = 1UL; 846 enum SQL_CP_ONE_PER_HENV = 2UL; 847 848 enum SQL_CP_STRICT_MATCH = 0UL; 849 enum SQL_CP_MATCH_DEFAULT = SQL_CP_STRICT_MATCH; 850 enum SQL_CP_RELAXED_MATCH = 1UL; 851 852 enum SQL_CS_CREATE_SCHEMA = 0x00000001L; 853 enum SQL_CS_AUTHORIZATION = 0x00000002L; 854 enum SQL_CS_DEFAULT_CHARACTER_SET = 0x00000004L; 855 856 enum SQL_CT_COLUMN_COLLATION = 0x00000800L; 857 enum SQL_CT_COLUMN_CONSTRAINT = 0x00000200L; 858 enum SQL_CT_COLUMN_DEFAULT = 0x00000400L; 859 enum SQL_CT_COMMIT_DELETE = 0x00000004L; 860 enum SQL_CT_COMMIT_PRESERVE = 0x00000002L; 861 enum SQL_CT_CONSTRAINT_DEFERRABLE = 0x00000080L; 862 enum SQL_CT_CONSTRAINT_INITIALLY_DEFERRED = 0x00000020L; 863 enum SQL_CT_CONSTRAINT_INITIALLY_IMMEDIATE = 0x00000040L; 864 enum SQL_CT_CONSTRAINT_NAME_DEFINITION = 0x00002000L; 865 enum SQL_CT_CONSTRAINT_NON_DEFERRABLE = 0x00000100L; 866 enum SQL_CT_CREATE_TABLE = 0x00000001L; 867 enum SQL_CT_GLOBAL_TEMPORARY = 0x00000008L; 868 enum SQL_CT_LOCAL_TEMPORARY = 0x00000010L; 869 enum SQL_CT_TABLE_CONSTRAINT = 0x00001000L; 870 871 enum SQL_CTR_CREATE_TRANSLATION = 0x00000001L; 872 873 enum SQL_CU_DML_STATEMENTS = SQL_QU_DML_STATEMENTS; 874 enum SQL_CU_INDEX_DEFINITION = SQL_QU_INDEX_DEFINITION; 875 enum SQL_CU_PRIVILEGE_DEFINITION = SQL_QU_PRIVILEGE_DEFINITION; 876 enum SQL_CU_PROCEDURE_INVOCATION = SQL_QU_PROCEDURE_INVOCATION; 877 enum SQL_CU_TABLE_DEFINITION = SQL_QU_TABLE_DEFINITION; 878 879 enum SQL_CVT_INTERVAL_YEAR_MONTH = 0x00080000L; 880 enum SQL_CVT_INTERVAL_DAY_TIME = 0x00100000L; 881 enum SQL_CVT_WCHAR = 0x00200000L; 882 enum SQL_CVT_WLONGVARCHAR = 0x00400000L; 883 enum SQL_CVT_WVARCHAR = 0x00800000L; 884 enum SQL_CVT_GUID = 0x01000000L; 885 886 enum SQL_DA_DROP_ASSERTION = 0x00000001L; 887 enum SQL_DATETIME_LITERALS = 119; 888 889 enum SQL_DB_DISCONNECT = 1UL; 890 enum SQL_DB_RETURN_TO_POOL = 0UL; 891 enum SQL_DB_DEFAULT = SQL_DB_RETURN_TO_POOL; 892 893 enum SQL_DC_DROP_COLLATION = 0x00000001L; 894 enum SQL_DCS_DROP_CHARACTER_SET = 0x00000001L; 895 enum SQL_DD_CASCADE = 0x00000004L; 896 enum SQL_DD_DROP_DOMAIN = 0x00000001L; 897 enum SQL_DD_RESTRICT = 0x00000002L; 898 enum SQL_DDL_INDEX = 170; 899 enum SQL_DELETE_BY_BOOKMARK = 6; 900 enum SQL_DESC_ARRAY_SIZE = 20; 901 enum SQL_DESC_ARRAY_STATUS_PTR = 21; 902 enum SQL_DESC_AUTO_UNIQUE_VALUE = SQL_COLUMN_AUTO_INCREMENT; 903 enum SQL_DESC_BASE_COLUMN_NAME = 22; 904 enum SQL_DESC_BASE_TABLE_NAME = 23; 905 enum SQL_DESC_BIND_OFFSET_PTR = 24; 906 enum SQL_DESC_BIND_TYPE = 25; 907 enum SQL_DESC_CASE_SENSITIVE = SQL_COLUMN_CASE_SENSITIVE; 908 enum SQL_DESC_CATALOG_NAME = SQL_COLUMN_QUALIFIER_NAME; 909 enum SQL_DESC_CONCISE_TYPE = SQL_COLUMN_TYPE; 910 enum SQL_DESC_DATETIME_INTERVAL_PRECISION = 26; 911 enum SQL_DESC_DISPLAY_SIZE = SQL_COLUMN_DISPLAY_SIZE; 912 enum SQL_DESC_FIXED_PREC_SCALE = SQL_COLUMN_MONEY; 913 enum SQL_DESC_LABEL = SQL_COLUMN_LABEL; 914 enum SQL_DESC_LITERAL_PREFIX = 27; 915 enum SQL_DESC_LITERAL_SUFFIX = 28; 916 enum SQL_DESC_LOCAL_TYPE_NAME = 29; 917 enum SQL_DESC_MAXIMUM_SCALE = 30; 918 enum SQL_DESC_MINIMUM_SCALE = 31; 919 enum SQL_DESC_NUM_PREC_RADIX = 32; 920 enum SQL_DESC_PARAMETER_TYPE = 33; 921 enum SQL_DESC_ROWS_PROCESSED_PTR = 34; 922 enum SQL_DESC_SCHEMA_NAME = SQL_COLUMN_OWNER_NAME; 923 enum SQL_DESC_SEARCHABLE = SQL_COLUMN_SEARCHABLE; 924 enum SQL_DESC_TABLE_NAME = SQL_COLUMN_TABLE_NAME; 925 enum SQL_DESC_TYPE_NAME = SQL_COLUMN_TYPE_NAME; 926 enum SQL_DESC_UNSIGNED = SQL_COLUMN_UNSIGNED; 927 enum SQL_DESC_UPDATABLE = SQL_COLUMN_UPDATABLE; 928 enum SQL_DI_CREATE_INDEX = 0x00000001L; 929 enum SQL_DI_DROP_INDEX = 0x00000002L; 930 931 enum SQL_DIAG_COLUMN_NUMBER = -1247; 932 enum SQL_DIAG_ROW_NUMBER = -1248; 933 enum SQL_DIAG_CURSOR_ROW_COUNT = -1249; 934 935 enum SQL_DL_SQL92_DATE = 0x00000001L; 936 enum SQL_DL_SQL92_INTERVAL_DAY = 0x00000020L; 937 enum SQL_DL_SQL92_INTERVAL_DAY_TO_HOUR = 0x00000400L; 938 enum SQL_DL_SQL92_INTERVAL_DAY_TO_MINUTE = 0x00000800L; 939 enum SQL_DL_SQL92_INTERVAL_DAY_TO_SECOND = 0x00001000L; 940 enum SQL_DL_SQL92_INTERVAL_HOUR = 0x00000040L; 941 enum SQL_DL_SQL92_INTERVAL_HOUR_TO_MINUTE = 0x00002000L; 942 enum SQL_DL_SQL92_INTERVAL_HOUR_TO_SECOND = 0x00004000L; 943 enum SQL_DL_SQL92_INTERVAL_MINUTE = 0x00000080L; 944 enum SQL_DL_SQL92_INTERVAL_MINUTE_TO_SECOND = 0x00008000L; 945 enum SQL_DL_SQL92_INTERVAL_MONTH = 0x00000010L; 946 enum SQL_DL_SQL92_INTERVAL_SECOND = 0x00000100L; 947 enum SQL_DL_SQL92_INTERVAL_YEAR = 0x00000008L; 948 enum SQL_DL_SQL92_INTERVAL_YEAR_TO_MONTH = 0x00000200L; 949 enum SQL_DL_SQL92_TIME = 0x00000002L; 950 enum SQL_DL_SQL92_TIMESTAMP = 0x00000004L; 951 enum SQL_DM_VER = 171; 952 enum SQL_DRIVER_HDESC = 135; 953 enum SQL_DROP_ASSERTION = 136; 954 enum SQL_DROP_CHARACTER_SET = 137; 955 enum SQL_DROP_COLLATION = 138; 956 enum SQL_DROP_DOMAIN = 139; 957 enum SQL_DROP_SCHEMA = 140; 958 enum SQL_DROP_TABLE = 141; 959 enum SQL_DROP_TRANSLATION = 142; 960 enum SQL_DROP_VIEW = 143; 961 enum SQL_DS_CASCADE = 0x00000004L; 962 enum SQL_DS_DROP_SCHEMA = 0x00000001L; 963 enum SQL_DS_RESTRICT = 0x00000002L; 964 enum SQL_DT_CASCADE = 0x00000004L; 965 enum SQL_DT_DROP_TABLE = 0x00000001L; 966 enum SQL_DT_RESTRICT = 0x00000002L; 967 enum SQL_DTC_DONE = 0L; 968 enum SQL_DTR_DROP_TRANSLATION = 0x00000001L; 969 enum SQL_DV_CASCADE = 0x00000004L; 970 enum SQL_DV_DROP_VIEW = 0x00000001L; 971 enum SQL_DV_RESTRICT = 0x00000002L; 972 enum SQL_DYNAMIC_CURSOR_ATTRIBUTES1 = 144; 973 enum SQL_DYNAMIC_CURSOR_ATTRIBUTES2 = 145; 974 enum SQL_EXT_API_LAST = SQL_API_SQLBINDPARAMETER; 975 enum SQL_EXT_API_START = 40; 976 enum SQL_FETCH_BY_BOOKMARK = 7; 977 enum SQL_FETCH_FIRST_SYSTEM = 32; 978 enum SQL_FETCH_FIRST_USER = 31; 979 enum SQL_FN_CVT_CAST = 0x00000002L; 980 enum SQL_FN_STR_BIT_LENGTH = 0x00080000L; 981 enum SQL_FN_STR_CHAR_LENGTH = 0x00100000L; 982 enum SQL_FN_STR_CHARACTER_LENGTH = 0x00200000L; 983 enum SQL_FN_STR_OCTET_LENGTH = 0x00400000L; 984 enum SQL_FN_STR_POSITION = 0x00800000L; 985 enum SQL_FN_TD_CURRENT_DATE = 0x00020000L; 986 enum SQL_FN_TD_CURRENT_TIME = 0x00040000L; 987 enum SQL_FN_TD_CURRENT_TIMESTAMP = 0x00080000L; 988 enum SQL_FN_TD_EXTRACT = 0x00100000L; 989 enum SQL_FORWARD_ONLY_CURSOR_ATTRIBUTES1 = 146; 990 enum SQL_FORWARD_ONLY_CURSOR_ATTRIBUTES2 = 147; 991 /* #define SQL_FUNC_EXISTS(exists, api) 992 ((*(((UWORD*) (exists)) + ((api) >> 4)) & (1 << ((api) & 15)) ) ? 993 SQL_TRUE : SQL_FALSE ) 994 */ 995 enum SQL_GB_COLLATE = 0x0004; 996 enum SQL_HANDLE_SENV = 5; 997 998 enum SQL_IK_NONE = 0; 999 enum SQL_IK_ASC = 1; 1000 enum SQL_IK_DESC = 2; 1001 enum SQL_IK_ALL = SQL_IK_ASC | SQL_IK_DESC; 1002 1003 enum SQL_INDEX_KEYWORDS = 148; 1004 enum SQL_INFO_DRIVER_START = 1000; 1005 enum SQL_INFO_LAST = SQL_QUALIFIER_LOCATION; 1006 enum SQL_INFO_SCHEMA_VIEWS = 149; 1007 enum SQL_INITIALLY_DEFERRED = 5; 1008 enum SQL_INITIALLY_IMMEDIATE = 6; 1009 enum SQL_INSERT_STATEMENT = 172; 1010 enum SQL_INTERVAL = 10; 1011 enum SQL_IS_INSERT_LITERALS = 0x00000001L; 1012 enum SQL_IS_INSERT_SEARCHED = 0x00000002L; 1013 enum SQL_IS_INTEGER = -6; 1014 enum SQL_IS_POINTER = -4; 1015 enum SQL_IS_SELECT_INTO = 0x00000004L; 1016 enum SQL_IS_SMALLINT = -8; 1017 enum SQL_IS_UINTEGER = -5; 1018 enum SQL_IS_USMALLINT = -7; 1019 enum SQL_ISV_ASSERTIONS = 0x00000001L; 1020 enum SQL_ISV_CHARACTER_SETS = 0x00000002L; 1021 enum SQL_ISV_CHECK_CONSTRAINTS = 0x00000004L; 1022 enum SQL_ISV_COLLATIONS = 0x00000008L; 1023 enum SQL_ISV_COLUMN_DOMAIN_USAGE = 0x00000010L; 1024 enum SQL_ISV_COLUMN_PRIVILEGES = 0x00000020L; 1025 enum SQL_ISV_COLUMNS = 0x00000040L; 1026 enum SQL_ISV_CONSTRAINT_COLUMN_USAGE = 0x00000080L; 1027 enum SQL_ISV_CONSTRAINT_TABLE_USAGE = 0x00000100L; 1028 enum SQL_ISV_DOMAIN_CONSTRAINTS = 0x00000200L; 1029 enum SQL_ISV_DOMAINS = 0x00000400L; 1030 enum SQL_ISV_KEY_COLUMN_USAGE = 0x00000800L; 1031 enum SQL_ISV_REFERENTIAL_CONSTRAINTS = 0x00001000L; 1032 enum SQL_ISV_SCHEMATA = 0x00002000L; 1033 enum SQL_ISV_SQL_LANGUAGES = 0x00004000L; 1034 enum SQL_ISV_TABLE_CONSTRAINTS = 0x00008000L; 1035 enum SQL_ISV_TABLE_PRIVILEGES = 0x00010000L; 1036 enum SQL_ISV_TABLES = 0x00020000L; 1037 enum SQL_ISV_TRANSLATIONS = 0x00040000L; 1038 enum SQL_ISV_USAGE_PRIVILEGES = 0x00080000L; 1039 enum SQL_ISV_VIEW_COLUMN_USAGE = 0x00100000L; 1040 enum SQL_ISV_VIEW_TABLE_USAGE = 0x00200000L; 1041 enum SQL_ISV_VIEWS = 0x00400000L; 1042 enum SQL_KEYSET_CURSOR_ATTRIBUTES1 = 150; 1043 enum SQL_KEYSET_CURSOR_ATTRIBUTES2 = 151; 1044 enum SQL_MAX_ASYNC_CONCURRENT_STATEMENTS = 10022; 1045 enum SQL_NO_COLUMN_NUMBER = -1; 1046 enum SQL_NO_ROW_NUMBER = -1; 1047 enum SQL_NOT_DEFERRABLE = 7; 1048 enum SQL_NUM_EXTENSIONS = SQL_EXT_API_LAST-SQL_EXT_API_START+1; 1049 enum SQL_NUM_FUNCTIONS = 23; 1050 enum SQL_ODBC_INTERFACE_CONFORMANCE = 152; 1051 1052 enum : ULONG { 1053 SQL_OIC_CORE = 1, 1054 SQL_OIC_LEVEL1, 1055 SQL_OIC_LEVEL2 1056 } 1057 enum : ULONG { 1058 SQL_OV_ODBC2 = 2, 1059 SQL_OV_ODBC3 = 3 1060 } 1061 1062 enum ULONG 1063 SQL_PARAM_BIND_BY_COLUMN = 0, 1064 SQL_PARAM_BIND_TYPE_DEFAULT = SQL_PARAM_BIND_BY_COLUMN; 1065 1066 enum SQL_PARAM_ARRAY_ROW_COUNTS = 153; 1067 enum SQL_PARAM_ARRAY_SELECTS = 154; 1068 enum SQL_PARAM_DIAG_UNAVAILABLE = 1; 1069 enum SQL_PARAM_ERROR = 5; 1070 enum SQL_PARAM_IGNORE = 1; 1071 enum SQL_PARAM_PROCEED = 0; 1072 enum SQL_PARAM_SUCCESS = 0; 1073 enum SQL_PARAM_SUCCESS_WITH_INFO = 6; 1074 enum SQL_PARAM_UNUSED = 7; 1075 1076 enum SQL_PARC_BATCH = 1; 1077 enum SQL_PARC_NO_BATCH = 2; 1078 enum SQL_PAS_BATCH = 1; 1079 enum SQL_PAS_NO_BATCH = 2; 1080 enum SQL_PAS_NO_SELECT = 3; 1081 1082 enum SQL_ROW_IGNORE = 1; 1083 enum SQL_ROW_NUMBER_UNKNOWN = -2; 1084 enum SQL_ROW_PROCEED = 0; 1085 enum SQL_ROW_SUCCESS_WITH_INFO = 6; 1086 1087 enum SQL_SC_FIPS127_2_TRANSITIONAL = 0x00000002L; 1088 enum SQL_SC_SQL92_ENTRY = 0x00000001L; 1089 enum SQL_SC_SQL92_FULL = 0x00000008L; 1090 enum SQL_SC_SQL92_INTERMEDIATE = 0x00000004L; 1091 1092 enum SQL_SCC_ISO92_CLI = 0x00000002L; 1093 enum SQL_SCC_XOPEN_CLI_VERSION1 = 0x00000001L; 1094 1095 enum SQL_SCHEMA_TERM = SQL_OWNER_TERM; 1096 enum SQL_SCHEMA_USAGE = SQL_OWNER_USAGE; 1097 enum SQL_SDF_CURRENT_DATE = 0x00000001L; 1098 enum SQL_SDF_CURRENT_TIME = 0x00000002L; 1099 enum SQL_SDF_CURRENT_TIMESTAMP = 0x00000004L; 1100 enum SQL_SFKD_CASCADE = 0x00000001L; 1101 enum SQL_SFKD_NO_ACTION = 0x00000002L; 1102 enum SQL_SFKD_SET_DEFAULT = 0x00000004L; 1103 enum SQL_SFKD_SET_NULL = 0x00000008L; 1104 enum SQL_SFKU_CASCADE = 0x00000001L; 1105 enum SQL_SFKU_NO_ACTION = 0x00000002L; 1106 enum SQL_SFKU_SET_DEFAULT = 0x00000004L; 1107 enum SQL_SFKU_SET_NULL = 0x00000008L; 1108 enum SQL_SG_DELETE_TABLE = 0x00000020L; 1109 enum SQL_SG_INSERT_COLUMN = 0x00000080L; 1110 enum SQL_SG_INSERT_TABLE = 0x00000040L; 1111 enum SQL_SG_REFERENCES_COLUMN = 0x00000200L; 1112 enum SQL_SG_REFERENCES_TABLE = 0x00000100L; 1113 enum SQL_SG_SELECT_TABLE = 0x00000400L; 1114 enum SQL_SG_UPDATE_COLUMN = 0x00001000L; 1115 enum SQL_SG_UPDATE_TABLE = 0x00000800L; 1116 enum SQL_SG_USAGE_ON_CHARACTER_SET = 0x00000002L; 1117 enum SQL_SG_USAGE_ON_COLLATION = 0x00000004L; 1118 enum SQL_SG_USAGE_ON_DOMAIN = 0x00000001L; 1119 enum SQL_SG_USAGE_ON_TRANSLATION = 0x00000008L; 1120 enum SQL_SG_WITH_GRANT_OPTION = 0x00000010L; 1121 enum SQL_SNVF_BIT_LENGTH = 0x00000001L; 1122 enum SQL_SNVF_CHAR_LENGTH = 0x00000002L; 1123 enum SQL_SNVF_CHARACTER_LENGTH = 0x00000004L; 1124 enum SQL_SNVF_EXTRACT = 0x00000008L; 1125 enum SQL_SNVF_OCTET_LENGTH = 0x00000010L; 1126 enum SQL_SNVF_POSITION = 0x00000020L; 1127 enum SQL_SP_BETWEEN = 0x00000800L; 1128 enum SQL_SP_COMPARISON = 0x00001000L; 1129 enum SQL_SP_EXISTS = 0x00000001L; 1130 enum SQL_SP_IN = 0x00000400L; 1131 enum SQL_SP_ISNOTNULL = 0x00000002L; 1132 enum SQL_SP_ISNULL = 0x00000004L; 1133 enum SQL_SP_LIKE = 0x00000200L; 1134 enum SQL_SP_MATCH_FULL = 0x00000008L; 1135 enum SQL_SP_MATCH_PARTIAL = 0x00000010L; 1136 enum SQL_SP_MATCH_UNIQUE_FULL = 0x00000020L; 1137 enum SQL_SP_MATCH_UNIQUE_PARTIAL = 0x00000040L; 1138 enum SQL_SP_OVERLAPS = 0x00000080L; 1139 enum SQL_SP_QUANTIFIED_COMPARISON = 0x00002000L; 1140 enum SQL_SP_UNIQUE = 0x00000100L; 1141 enum SQL_SQL_CONFORMANCE = 118; 1142 enum SQL_SQL92_DATETIME_FUNCTIONS = 155; 1143 enum SQL_SQL92_FOREIGN_KEY_DELETE_RULE = 156; 1144 enum SQL_SQL92_FOREIGN_KEY_UPDATE_RULE = 157; 1145 enum SQL_SQL92_GRANT = 158; 1146 enum SQL_SQL92_NUMERIC_VALUE_FUNCTIONS = 159; 1147 enum SQL_SQL92_PREDICATES = 160; 1148 enum SQL_SQL92_RELATIONAL_JOIN_OPERATORS = 161; 1149 enum SQL_SQL92_REVOKE = 162; 1150 enum SQL_SQL92_ROW_VALUE_CONSTRUCTOR = 163; 1151 enum SQL_SQL92_STRING_FUNCTIONS = 164; 1152 enum SQL_SQL92_VALUE_EXPRESSIONS = 165; 1153 enum SQL_SR_CASCADE = 0x00000020L; 1154 enum SQL_SR_DELETE_TABLE = 0x00000080L; 1155 enum SQL_SR_GRANT_OPTION_FOR = 0x00000010L; 1156 enum SQL_SR_INSERT_COLUMN = 0x00000200L; 1157 enum SQL_SR_INSERT_TABLE = 0x00000100L; 1158 enum SQL_SR_REFERENCES_COLUMN = 0x00000800L; 1159 enum SQL_SR_REFERENCES_TABLE = 0x00000400L; 1160 enum SQL_SR_RESTRICT = 0x00000040L; 1161 enum SQL_SR_SELECT_TABLE = 0x00001000L; 1162 enum SQL_SR_UPDATE_COLUMN = 0x00004000L; 1163 enum SQL_SR_UPDATE_TABLE = 0x00002000L; 1164 enum SQL_SR_USAGE_ON_CHARACTER_SET = 0x00000002L; 1165 enum SQL_SR_USAGE_ON_COLLATION = 0x00000004L; 1166 enum SQL_SR_USAGE_ON_DOMAIN = 0x00000001L; 1167 enum SQL_SR_USAGE_ON_TRANSLATION = 0x00000008L; 1168 enum SQL_SRJO_CORRESPONDING_CLAUSE = 0x00000001L; 1169 enum SQL_SRJO_CROSS_JOIN = 0x00000002L; 1170 enum SQL_SRJO_EXCEPT_JOIN = 0x00000004L; 1171 enum SQL_SRJO_FULL_OUTER_JOIN = 0x00000008L; 1172 enum SQL_SRJO_INNER_JOIN = 0x00000010L; 1173 enum SQL_SRJO_INTERSECT_JOIN = 0x00000020L; 1174 enum SQL_SRJO_LEFT_OUTER_JOIN = 0x00000040L; 1175 enum SQL_SRJO_NATURAL_JOIN = 0x00000080L; 1176 enum SQL_SRJO_RIGHT_OUTER_JOIN = 0x00000100L; 1177 enum SQL_SRJO_UNION_JOIN = 0x00000200L; 1178 enum SQL_SRVC_DEFAULT = 0x00000004L; 1179 enum SQL_SRVC_NULL = 0x00000002L; 1180 enum SQL_SRVC_ROW_SUBQUERY = 0x00000008L; 1181 enum SQL_SRVC_VALUE_EXPRESSION = 0x00000001L; 1182 enum SQL_SSF_CONVERT = 0x00000001L; 1183 enum SQL_SSF_LOWER = 0x00000002L; 1184 enum SQL_SSF_SUBSTRING = 0x00000008L; 1185 enum SQL_SSF_TRANSLATE = 0x00000010L; 1186 enum SQL_SSF_TRIM_BOTH = 0x00000020L; 1187 enum SQL_SSF_TRIM_LEADING = 0x00000040L; 1188 enum SQL_SSF_TRIM_TRAILING = 0x00000080L; 1189 enum SQL_SSF_UPPER = 0x00000004L; 1190 enum SQL_STANDARD_CLI_CONFORMANCE = 166; 1191 enum SQL_STATIC_CURSOR_ATTRIBUTES1 = 167; 1192 enum SQL_STATIC_CURSOR_ATTRIBUTES2 = 168; 1193 enum SQL_SU_DML_STATEMENTS = SQL_OU_DML_STATEMENTS; 1194 enum SQL_SU_INDEX_DEFINITION = SQL_OU_INDEX_DEFINITION; 1195 enum SQL_SU_PRIVILEGE_DEFINITION = SQL_OU_PRIVILEGE_DEFINITION; 1196 enum SQL_SU_PROCEDURE_INVOCATION = SQL_OU_PROCEDURE_INVOCATION; 1197 enum SQL_SU_TABLE_DEFINITION = SQL_OU_TABLE_DEFINITION; 1198 enum SQL_SVE_CASE = 0x00000001L; 1199 enum SQL_SVE_CAST = 0x00000002L; 1200 enum SQL_SVE_COALESCE = 0x00000004L; 1201 enum SQL_SVE_NULLIF = 0x00000008L; 1202 enum SQL_UB_FIXED = SQL_UB_ON; 1203 enum SQL_UB_VARIABLE = 2UL; 1204 enum SQL_UNION_STATEMENT = SQL_UNION; 1205 enum SQL_UPDATE_BY_BOOKMARK = 5; 1206 enum SQL_US_UNION = SQL_U_UNION; 1207 enum SQL_US_UNION_ALL = SQL_U_UNION_ALL; 1208 }//[Yes] #endif /* ODBCVER >= 0x300 */ 1209 static if (ODBCVER >= 0x0350) 1210 { 1211 enum SQL_DESC_ROWVER = 35; 1212 enum SQL_GUID = -11; 1213 enum SQL_C_GUID = SQL_GUID; 1214 //#ifdef ODBC_STD 1215 //#define SQLAllocHandle SQLAllocHandleStd 1216 //#define SQLAllocEnv(p) SQLAllocHandleStd(SQL_HANDLE_ENV, SQL_NULL_HANDLE, p) 1217 //#define SQL_YEAR SQL_CODE_YEAR 1218 //#define SQL_MONTH SQL_CODE_MONTH 1219 //#define SQL_DAY SQL_CODE_DAY 1220 //#define SQL_HOUR SQL_CODE_HOUR 1221 //#define SQL_MINUTE SQL_CODE_MINUTE 1222 //#define SQL_SECOND SQL_CODE_SECOND 1223 //#define SQL_YEAR_TO_MONTH SQL_CODE_YEAR_TO_MONTH 1224 //#define SQL_DAY_TO_HOUR SQL_CODE_DAY_TO_HOUR 1225 //#define SQL_DAY_TO_MINUTE SQL_CODE_DAY_TO_MINUTE 1226 //#define SQL_DAY_TO_SECOND SQL_CODE_DAY_TO_SECOND 1227 //#define SQL_HOUR_TO_MINUTE SQL_CODE_HOUR_TO_MINUTE 1228 //#define SQL_HOUR_TO_SECOND SQL_CODE_HOUR_TO_SECOND 1229 //#define SQL_MINUTE_TO_SECOND SQL_CODE_MINUTE_TO_SECOND 1230 //#endif /* ODBC_STD */ 1231 }//#endif /* ODBCVER >= 0x0350 */ 1232 1233 //static if (ODBCVER >= 0x0351) 1234 //{ 1235 enum SQL_ATTR_ANSI_APP=115; 1236 enum SQL_AA_TRUE=1L; 1237 enum SQL_AA_FALSE=0L; 1238 //}//[Yes] #endif 1239 1240 enum TRACE_VERSION=1000; 1241 enum TRACE_ON=1; 1242 1243 const char [] SQL_ODBC_KEYWORDS = 1244 "ABSOLUTE, ACTION, ADA, ADD, ALL, ALLOCATE, ALTER, AND, ANY, ARE, AS, " 1245 ~ "ASC, ASSERTION, AT, AUTHORIZATION, AVG, " 1246 ~ "BEGIN, BETWEEN, BIT, BIT_LENGTH, BOTH, BY, CASCADE, CASCADED, CASE, CAST, CATALOG, " 1247 ~ "CHAR, CHAR_LENGTH, CHARACTER, CHARACTER_LENGTH, CHECK, CLOSE, COALESCE, " 1248 ~ "COLLATE, COLLATION, COLUMN, COMMIT, CONNECT, CONNECTION, CONSTRAINT, " 1249 ~ "CONSTRAINTS, CONTINUE, CONVERT, CORRESPONDING, COUNT, CREATE, CROSS, CURRENT, " 1250 ~ "CURRENT_DATE, CURRENT_TIME, CURRENT_TIMESTAMP, CURRENT_USER, CURSOR, " 1251 ~ "DATE, DAY, DEALLOCATE, DEC, DECIMAL, DECLARE, DEFAULT, DEFERRABLE, " 1252 ~ "DEFERRED, DELETE, DESC, DESCRIBE, DESCRIPTOR, DIAGNOSTICS, DISCONNECT, " 1253 ~ "DISTINCT, DOMAIN, DOUBLE, DROP, " 1254 ~ "ELSE, END, END-EXEC, ESCAPE, EXCEPT, EXCEPTION, EXEC, EXECUTE, " 1255 ~ "EXISTS, EXTERNAL, EXTRACT, " 1256 ~ "FALSE, FETCH, FIRST, FLOAT, FOR, FOREIGN, FORTRAN, FOUND, FROM, FULL, " 1257 ~ "GET, GLOBAL, GO, GOTO, GRANT, GROUP, HAVING, HOUR, " 1258 ~ "IDENTITY, IMMEDIATE, IN, INCLUDE, INDEX, INDICATOR, INITIALLY, INNER, " 1259 ~ "INPUT, INSENSITIVE, INSERT, INT, INTEGER, INTERSECT, INTERVAL, INTO, IS, ISOLATION, " 1260 ~ "JOIN, KEY, LANGUAGE, LAST, LEADING, LEFT, LEVEL, LIKE, LOCAL, LOWER, " 1261 ~ "MATCH, MAX, MIN, MINUTE, MODULE, MONTH, " 1262 ~ "NAMES, NATIONAL, NATURAL, NCHAR, NEXT, NO, NONE, NOT, NULL, NULLIF, NUMERIC, " 1263 ~ "OCTET_LENGTH, OF, ON, ONLY, OPEN, OPTION, OR, ORDER, OUTER, OUTPUT, OVERLAPS, " 1264 ~ "PAD, PARTIAL, PASCAL, PLI, POSITION, PRECISION, PREPARE, PRESERVE, " 1265 ~ "PRIMARY, PRIOR, PRIVILEGES, PROCEDURE, PUBLIC, " 1266 ~ "READ, REAL, REFERENCES, RELATIVE, RESTRICT, REVOKE, RIGHT, ROLLBACK, ROWS" 1267 ~ "SCHEMA, SCROLL, SECOND, SECTION, SELECT, SESSION, SESSION_USER, SET, SIZE, " 1268 ~ "SMALLINT, SOME, SPACE, SQL, SQLCA, SQLCODE, SQLERROR, SQLSTATE, SQLWARNING, " 1269 ~ "SUBSTRING, SUM, SYSTEM_USER, " 1270 ~ "TABLE, TEMPORARY, THEN, TIME, TIMESTAMP, TIMEZONE_HOUR, TIMEZONE_MINUTE, " 1271 ~ "TO, TRAILING, TRANSACTION, TRANSLATE, TRANSLATION, TRIM, TRUE, " 1272 ~ "UNION, UNIQUE, UNKNOWN, UPDATE, UPPER, USAGE, USER, USING, " 1273 ~ "VALUE, VALUES, VARCHAR, VARYING, VIEW, WHEN, WHENEVER, WHERE, WITH, WORK, WRITE, " 1274 ~ "YEAR, ZONE"; 1275 extern (System) { 1276 SQLRETURN SQLDriverConnect(SQLHDBC, SQLHWND, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLSMALLINT*, SQLUSMALLINT); 1277 SQLRETURN SQLBrowseConnect(SQLHDBC, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLSMALLINT*); 1278 SQLRETURN SQLColumnPrivileges(SQLHSTMT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT); 1279 SQLRETURN SQLColAttributes(SQLHSTMT, SQLUSMALLINT, SQLUSMALLINT, SQLPOINTER, SQLSMALLINT, SQLSMALLINT*, SQLLEN*); 1280 SQLRETURN SQLDescribeParam(SQLHSTMT, SQLUSMALLINT, SQLSMALLINT*, SQLULEN*, SQLSMALLINT*, SQLSMALLINT*); 1281 SQLRETURN SQLExtendedFetch(SQLHSTMT, SQLUSMALLINT, SQLINTEGER, SQLUINTEGER*, SQLUSMALLINT*); 1282 SQLRETURN SQLForeignKeys(SQLHSTMT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT); 1283 SQLRETURN SQLMoreResults(SQLHSTMT); 1284 SQLRETURN SQLNativeSql(SQLHDBC, SQLCHAR*, SQLINTEGER, SQLCHAR*, SQLINTEGER, SQLINTEGER*); 1285 SQLRETURN SQLNumParams(SQLHSTMT, SQLSMALLINT*); 1286 SQLRETURN SQLParamOptions(SQLHSTMT, SQLUINTEGER, SQLUINTEGER*); 1287 SQLRETURN SQLPrimaryKeys(SQLHSTMT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT); 1288 SQLRETURN SQLProcedureColumns(SQLHSTMT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT); 1289 SQLRETURN SQLProcedures(SQLHSTMT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT); 1290 SQLRETURN SQLSetPos(SQLHSTMT, SQLUSMALLINT, SQLUSMALLINT, SQLUSMALLINT); 1291 SQLRETURN SQLTablePrivileges(SQLHSTMT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT, SQLCHAR*, SQLSMALLINT); 1292 SQLRETURN SQLDrivers(SQLHENV, SQLUSMALLINT, SQLCHAR*, SQLSMALLINT, SQLSMALLINT*, SQLCHAR*, SQLSMALLINT, SQLSMALLINT*); 1293 SQLRETURN SQLBindParameter(SQLHSTMT, SQLUSMALLINT, SQLSMALLINT, SQLSMALLINT, SQLSMALLINT, SQLULEN, SQLSMALLINT, SQLPOINTER, SQLLEN, SQLLEN*); 1294 SQLRETURN SQLSetScrollOptions(SQLHSTMT, SQLUSMALLINT, SQLLEN, SQLUSMALLINT);/* deprecated */ 1295 DWORD ODBCGetTryWaitValue(); 1296 BOOL ODBCSetTryWaitValue(DWORD); 1297 RETCODE TraceOpenLogFile(LPWSTR, LPWSTR, DWORD); 1298 RETCODE TraceCloseLogFile(); 1299 VOID TraceReturn(RETCODE, RETCODE); 1300 DWORD TraceVersion(); 1301 //static if (ODBCVER >= 0x0300) 1302 //{ 1303 SQLRETURN SQLBulkOperations(SQLHSTMT, SQLSMALLINT); 1304 SQLRETURN SQLAllocHandleStd( SQLSMALLINT, SQLHANDLE, SQLHANDLE*); 1305 //} 1306 }