INFO.H
上传用户:bangxh
上传日期:2007-01-31
资源大小:42235k
文件大小:7k
源码类别:

Windows编程

开发平台:

Visual C++

  1. //*---------------------------------------------------------------------------------
  2. //|  ODBC System Administrator
  3. //|
  4. //|  This code is furnished on an as-is basis as part of the ODBC SDK and is
  5. //|  intended for example purposes only.
  6. //|
  7. //|   Title:   INFO.H
  8. //|      This file contains the prototypes and defines for executing SQL
  9. //|         statements and displaying their results.
  10. //*---------------------------------------------------------------------------------
  11. #ifndef info_DEFS
  12. #define info_DEFS
  13. #include <windows.h>
  14. #include "standard.h"
  15. #include "errcheck.h"
  16. #include "ctl3d.h"
  17. #include "results.h"
  18. #include "child.h"
  19. #include "execute.h"
  20. #include "stdlib.h"
  21. //*---------------------------------------------------------------------------------
  22. //|   Macros and Defines
  23. //*---------------------------------------------------------------------------------
  24. #define  MAX_QUALIFIER     45
  25. #define  MAX_OWNER         40
  26. #define  MAX_NAME          40
  27. #define  MAX_TYPE          40
  28. #define  MAX_SPEC_VAL      128
  29. #define LIST_ALL        0
  30. #define LIST_TABLES     1
  31. #define LIST_VIEWS      2        
  32. #define  USER_SETCHECKSTATE         WM_USER + 1
  33. #define  USER_SETBUTTONSTATE        WM_USER + 2
  34. #define  USER_RESETLIST             WM_USER + 3
  35. #define  USER_SETSTATES             WM_USER + 4
  36. #define  USER_SETDEFAULTS           WM_USER + 5
  37. #define  IDE_QUALIFIER     151
  38. #define  IDE_OWNER         153
  39. #define  IDE_NAME          155
  40. #define  IDL_LIST          157
  41. #define  IDX_ALL           158
  42. #define  IDX_TABLES        159
  43. #define  IDX_VIEWS         160
  44. #define  IDL_PIPES         162
  45. #define  LIST_WIDTH        184
  46. #define SQL_FN_IDS_BASE 100
  47. #define idsSQLAllocConnect      SQL_FN_IDS_BASE+1
  48. #define idsSQLAllocEnv          SQL_FN_IDS_BASE+2
  49. #define idsSQLAllocHandle       SQL_FN_IDS_BASE+3
  50. #define idsSQLAllocStmt         SQL_FN_IDS_BASE+4
  51. #define idsSQLBindCol           SQL_FN_IDS_BASE+5
  52. #define idsSQLBindParam         SQL_FN_IDS_BASE+6
  53. #define idsSQLBindParameter     SQL_FN_IDS_BASE+7
  54. #define idsSQLBrowseConnect     SQL_FN_IDS_BASE+8
  55. #define idsSQLBulkOperations    SQL_FN_IDS_BASE+9
  56. #define idsSQLCancel            SQL_FN_IDS_BASE+10
  57. #define idsSQLCloseCursor       SQL_FN_IDS_BASE+11
  58. #define idsSQLColAttribute      SQL_FN_IDS_BASE+12
  59. #define idsSQLColAttributes     SQL_FN_IDS_BASE+13
  60. #define idsSQLColumnPrivileges  SQL_FN_IDS_BASE+14
  61. #define idsSQLColumns           SQL_FN_IDS_BASE+15
  62. #define idsSQLConnect           SQL_FN_IDS_BASE+16
  63. #define idsSQLCopyDesc          SQL_FN_IDS_BASE+17
  64. #define idsSQLDataSources       SQL_FN_IDS_BASE+18
  65. #define idsSQLDescribeCol       SQL_FN_IDS_BASE+19
  66. #define idsSQLDescribeParam     SQL_FN_IDS_BASE+20
  67. #define idsSQLDisconnect        SQL_FN_IDS_BASE+21
  68. #define idsSQLDriverConnect     SQL_FN_IDS_BASE+22
  69. #define idsSQLEndTran           SQL_FN_IDS_BASE+23
  70. #define idsSQLError             SQL_FN_IDS_BASE+24
  71. #define idsSQLExecDirect        SQL_FN_IDS_BASE+25
  72. #define idsSQLExecute           SQL_FN_IDS_BASE+26
  73. #define idsSQLExtendedFetch     SQL_FN_IDS_BASE+27
  74. #define idsSQLFetch             SQL_FN_IDS_BASE+28
  75. #define idsSQLFetchScroll       SQL_FN_IDS_BASE+29
  76. #define idsSQLForeignKeys       SQL_FN_IDS_BASE+30
  77. #define idsSQLFreeConnect       SQL_FN_IDS_BASE+31
  78. #define idsSQLFreeEnv           SQL_FN_IDS_BASE+32
  79. #define idsSQLFreeHandle        SQL_FN_IDS_BASE+33
  80. #define idsSQLFreeStmt          SQL_FN_IDS_BASE+34
  81. #define idsSQLGetConnectAttr    SQL_FN_IDS_BASE+35
  82. #define idsSQLGetConnectOption  SQL_FN_IDS_BASE+36
  83. #define idsSQLGetCursorName     SQL_FN_IDS_BASE+37
  84. #define idsSQLGetData           SQL_FN_IDS_BASE+38
  85. #define idsSQLGetDescField      SQL_FN_IDS_BASE+39
  86. #define idsSQLGetDescRec        SQL_FN_IDS_BASE+40
  87. #define idsSQLGetDiagField      SQL_FN_IDS_BASE+41
  88. #define idsSQLGetDiagRec        SQL_FN_IDS_BASE+42
  89. #define idsSQLGetEnvAttr        SQL_FN_IDS_BASE+43
  90. #define idsSQLGetFunctions      SQL_FN_IDS_BASE+44
  91. #define idsSQLGetInfo           SQL_FN_IDS_BASE+45
  92. #define idsSQLGetStmtAttr       SQL_FN_IDS_BASE+46
  93. #define idsSQLGetStmtOption     SQL_FN_IDS_BASE+47
  94. #define idsSQLGetTypeInfo       SQL_FN_IDS_BASE+48
  95. #define idsSQLMoreResults       SQL_FN_IDS_BASE+49
  96. #define idsSQLNativeSQL         SQL_FN_IDS_BASE+50
  97. #define idsSQLNumParams         SQL_FN_IDS_BASE+51
  98. #define idsSQLNumResultCols     SQL_FN_IDS_BASE+52
  99. #define idsSQLParamOptions      SQL_FN_IDS_BASE+53
  100. #define idsSQLPrepare           SQL_FN_IDS_BASE+54
  101. #define idsSQLPrimaryKeys       SQL_FN_IDS_BASE+55
  102. #define idsSQLProcedureColumns  SQL_FN_IDS_BASE+56
  103. #define idsSQLProcedures        SQL_FN_IDS_BASE+57
  104. #define idsSQLPutData           SQL_FN_IDS_BASE+58
  105. #define idsSQLRowCount          SQL_FN_IDS_BASE+59
  106. #define idsSQLSetConnectAttr    SQL_FN_IDS_BASE+60
  107. #define idsSQLSetConnectOption  SQL_FN_IDS_BASE+61
  108. #define idsSQLSetCursorName     SQL_FN_IDS_BASE+62
  109. #define idsSQLSetDescField      SQL_FN_IDS_BASE+63
  110. #define idsSQLSetDescRec        SQL_FN_IDS_BASE+64
  111. #define idsSQLSetEnvAttr        SQL_FN_IDS_BASE+65
  112. #define idsSQLSetParam          SQL_FN_IDS_BASE+66
  113. #define idsSQLSetPos            SQL_FN_IDS_BASE+67
  114. #define idsSQLSetScrollOptions  SQL_FN_IDS_BASE+68
  115. #define idsSQLSetStmtAttr       SQL_FN_IDS_BASE+69
  116. #define idsSQLSetStmtOption     SQL_FN_IDS_BASE+70
  117. #define idsSQLSpecialColumns    SQL_FN_IDS_BASE+71
  118. #define idsSQLStatistics        SQL_FN_IDS_BASE+72
  119. #define idsSQLTablePrivileges   SQL_FN_IDS_BASE+73
  120. #define idsSQLTables            SQL_FN_IDS_BASE+74
  121. #define idsSQLTransact          SQL_FN_IDS_BASE+75
  122. #define IDD_EDIT_PIPE                             700
  123. #define IDC_NAME                                  701
  124. #define IDB_NEW                                   702
  125. #define IDB_DELETE                                703
  126. #define IDE_SQL                                   704
  127. #define IDR_VALUE                                 705
  128. #define IDR_ADDRESS                               706
  129. #define IDE_PARMS                                 707
  130. #define IDX_DELETE                                708
  131. #define IDD_NEW_PIPE                              730
  132. #define IDD_DO_PIPE                               750
  133. //*---------------------------------------------------------------------------------
  134. //|   Global variables
  135. //*---------------------------------------------------------------------------------
  136. extern dCSEG(char) szResultsClass[];
  137. extern dCSEG(char) szODBCFunctions[];
  138. //*---------------------------------------------------------------------------------
  139. //|   Function prototypes
  140. //*---------------------------------------------------------------------------------
  141. void EditPipe(CHILDINFO FAR * ci);
  142. BOOL DisplayGetInfo(CHILDINFO FAR * ci);
  143. BOOL DisplayODBCFunctions(CHILDINFO FAR * ci);
  144. BOOL DisplayODBCDataSources(CHILDINFO FAR * ci);
  145. BOOL DisplayODBCDataTypes(CHILDINFO FAR * ci);
  146. void INTFUN HandlePipe(lpCHILDINFO lpci, lpRESULTSINFO lpri);
  147. #endif