2
0

odbcinst.h 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639
  1. /*
  2. * odbcinst.h
  3. *
  4. * $Id$
  5. *
  6. * iODBC Installer defines
  7. *
  8. * The iODBC driver manager.
  9. *
  10. * Copyright (C) 1996-2021 OpenLink Software <[email protected]>
  11. * All Rights Reserved.
  12. *
  13. * This software is released under the terms of either of the following
  14. * licenses:
  15. *
  16. * - GNU Library General Public License (see LICENSE.LGPL)
  17. * - The BSD License (see LICENSE.BSD).
  18. *
  19. * Note that the only valid version of the LGPL license as far as this
  20. * project is concerned is the original GNU Library General Public License
  21. * Version 2, dated June 1991.
  22. *
  23. * While not mandated by the BSD license, any patches you make to the
  24. * iODBC source code may be contributed back into the iODBC project
  25. * at your discretion. Contributions will benefit the Open Source and
  26. * Data Access community as a whole. Submissions may be made at:
  27. *
  28. * http://www.iodbc.org
  29. *
  30. *
  31. * GNU Library Generic Public License Version 2
  32. * ============================================
  33. * This library is free software; you can redistribute it and/or
  34. * modify it under the terms of the GNU Library General Public
  35. * License as published by the Free Software Foundation; only
  36. * Version 2 of the License dated June 1991.
  37. *
  38. * This library is distributed in the hope that it will be useful,
  39. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  40. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  41. * Library General Public License for more details.
  42. *
  43. * You should have received a copy of the GNU Library General Public
  44. * License along with this library; if not, write to the Free
  45. * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  46. *
  47. *
  48. * The BSD License
  49. * ===============
  50. * Redistribution and use in source and binary forms, with or without
  51. * modification, are permitted provided that the following conditions
  52. * are met:
  53. *
  54. * 1. Redistributions of source code must retain the above copyright
  55. * notice, this list of conditions and the following disclaimer.
  56. * 2. Redistributions in binary form must reproduce the above copyright
  57. * notice, this list of conditions and the following disclaimer in
  58. * the documentation and/or other materials provided with the
  59. * distribution.
  60. * 3. Neither the name of OpenLink Software Inc. nor the names of its
  61. * contributors may be used to endorse or promote products derived
  62. * from this software without specific prior written permission.
  63. *
  64. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  65. * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  66. * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  67. * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL OPENLINK OR
  68. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
  69. * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  70. * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
  71. * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
  72. * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
  73. * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  74. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  75. */
  76. #ifndef _ODBCINST_H
  77. #define _ODBCINST_H
  78. /*
  79. * Set default specification to ODBC 3.51
  80. */
  81. #ifndef ODBCVER
  82. #define ODBCVER 0x0351
  83. #endif
  84. #ifndef _SQL_H
  85. #include <sql.h>
  86. #endif
  87. #ifndef _SQLEXT_H
  88. #include <sqlext.h>
  89. #endif
  90. #ifdef __cplusplus
  91. extern "C" {
  92. #endif
  93. #ifndef EXPORT
  94. #define EXPORT
  95. #endif
  96. #ifndef SYS_ODBCINST_INI
  97. # if defined(__BEOS__)
  98. # define SYS_ODBCINST_INI "/boot/beos/etc/odbcinst.ini"
  99. # endif
  100. # if defined(macintosh)
  101. # ifdef __POWERPC__
  102. # define SYS_ODBCINST_INI "Boot:System Folder:Preferences:ODBC Installer Preferences PPC"
  103. # else
  104. # define SYS_ODBCINST_INI "Boot:System Folder:Preferences:ODBC Installer Preferences"
  105. # endif
  106. # else
  107. # define SYS_ODBCINST_INI "/etc/odbcinst.ini"
  108. # endif
  109. #endif
  110. #ifndef SYS_ODBC_INI
  111. # if defined(__BEOS__)
  112. # define SYS_ODBC_INI "/boot/beos/etc/odbc.ini"
  113. # endif
  114. # if defined(macintosh)
  115. # ifdef __POWERPC__
  116. # define SYS_ODBC_INI "Boot:System Folder:Preferences:ODBC Preferences PPC"
  117. # else
  118. # define SYS_ODBC_INI "Boot:System Folder:Preferences:ODBC Preferences"
  119. # endif
  120. # else
  121. # define SYS_ODBC_INI "/etc/odbc.ini"
  122. # endif
  123. #endif
  124. #ifndef DEFAULT_FILEDSNPATH
  125. # if defined(__BEOS__)
  126. # define DEFAULT_FILEDSNPATH "/boot/beos/etc/ODBCDataSources"
  127. # elif defined(macintosh)
  128. # ifdef __POWERPC__
  129. # define DEFAULT_FILEDSNPATH "Boot:System Folder:Preferences:ODBC Preferences PPC:ODBCDataSources"
  130. # else
  131. # define DEFAULT_FILEDSNPATH "Boot:System Folder:Preferences:ODBC Preferences:ODBCDataSources"
  132. # endif
  133. # elif defined (__APPLE__)
  134. # define DEFAULT_FILEDSNPATH "/Library/ODBC/ODBCDataSources"
  135. # else
  136. # define DEFAULT_FILEDSNPATH "/etc/ODBCDataSources"
  137. # endif
  138. #endif
  139. #define USERDSN_ONLY 0
  140. #define SYSTEMDSN_ONLY 1
  141. #ifdef WIN32
  142. #define INSTAPI __stdcall
  143. #else
  144. #define INSTAPI
  145. #endif
  146. /*
  147. * SQLConfigDataSource
  148. */
  149. #define ODBC_ADD_DSN 1
  150. #define ODBC_CONFIG_DSN 2
  151. #define ODBC_REMOVE_DSN 3
  152. #if (ODBCVER >= 0x0250)
  153. #define ODBC_ADD_SYS_DSN 4
  154. #define ODBC_CONFIG_SYS_DSN 5
  155. #define ODBC_REMOVE_SYS_DSN 6
  156. #if (ODBCVER >= 0x0300)
  157. #define ODBC_REMOVE_DEFAULT_DSN 7
  158. #endif /* ODBCVER >= 0x0300 */
  159. /* install request flags */
  160. #define ODBC_INSTALL_INQUIRY 1
  161. #define ODBC_INSTALL_COMPLETE 2
  162. /* config driver flags */
  163. #define ODBC_INSTALL_DRIVER 1
  164. #define ODBC_REMOVE_DRIVER 2
  165. #define ODBC_CONFIG_DRIVER 3
  166. #define ODBC_CONFIG_DRIVER_MAX 100
  167. #endif
  168. /* SQLGetConfigMode and SQLSetConfigMode flags */
  169. #if (ODBCVER >= 0x0300)
  170. #define ODBC_BOTH_DSN 0
  171. #define ODBC_USER_DSN 1
  172. #define ODBC_SYSTEM_DSN 2
  173. #endif /* ODBCVER >= 0x0300 */
  174. /* SQLInstallerError code */
  175. #if (ODBCVER >= 0x0300)
  176. #define ODBC_ERROR_GENERAL_ERR 1
  177. #define ODBC_ERROR_INVALID_BUFF_LEN 2
  178. #define ODBC_ERROR_INVALID_HWND 3
  179. #define ODBC_ERROR_INVALID_STR 4
  180. #define ODBC_ERROR_INVALID_REQUEST_TYPE 5
  181. #define ODBC_ERROR_COMPONENT_NOT_FOUND 6
  182. #define ODBC_ERROR_INVALID_NAME 7
  183. #define ODBC_ERROR_INVALID_KEYWORD_VALUE 8
  184. #define ODBC_ERROR_INVALID_DSN 9
  185. #define ODBC_ERROR_INVALID_INF 10
  186. #define ODBC_ERROR_REQUEST_FAILED 11
  187. #define ODBC_ERROR_INVALID_PATH 12
  188. #define ODBC_ERROR_LOAD_LIB_FAILED 13
  189. #define ODBC_ERROR_INVALID_PARAM_SEQUENCE 14
  190. #define ODBC_ERROR_INVALID_LOG_FILE 15
  191. #define ODBC_ERROR_USER_CANCELED 16
  192. #define ODBC_ERROR_USAGE_UPDATE_FAILED 17
  193. #define ODBC_ERROR_CREATE_DSN_FAILED 18
  194. #define ODBC_ERROR_WRITING_SYSINFO_FAILED 19
  195. #define ODBC_ERROR_REMOVE_DSN_FAILED 20
  196. #define ODBC_ERROR_OUT_OF_MEM 21
  197. #define ODBC_ERROR_OUTPUT_STRING_TRUNCATED 22
  198. #define ODBC_ERROR_DRIVER_SPECIFIC 23
  199. #endif /* ODBCVER >= 0x0300 */
  200. /*
  201. * Function Prototypes
  202. */
  203. BOOL INSTAPI
  204. SQLGetConfigMode (
  205. UWORD* pwConfigMode);
  206. BOOL INSTAPI
  207. SQLInstallDriverEx (
  208. LPCSTR lpszDriver,
  209. LPCSTR lpszPathIn,
  210. LPSTR lpszPathOut,
  211. WORD cbPathOutMax,
  212. WORD* pcbPathOut,
  213. WORD fRequest,
  214. LPDWORD lpdwUsageCount);
  215. BOOL INSTAPI
  216. SQLInstallDriverExW (
  217. LPCWSTR lpszDriver,
  218. LPCWSTR lpszPathIn,
  219. LPWSTR lpszPathOut,
  220. WORD cbPathOutMax,
  221. WORD* pcbPathOut,
  222. WORD fRequest,
  223. LPDWORD lpdwUsageCount);
  224. RETCODE INSTAPI
  225. SQLInstallerError (
  226. WORD iError,
  227. DWORD* pfErrorCode,
  228. LPSTR lpszErrorMsg,
  229. WORD cbErrorMsgMax,
  230. WORD* pcbErrorMsg);
  231. RETCODE INSTAPI
  232. SQLInstallerErrorW (
  233. WORD iError,
  234. DWORD* pfErrorCode,
  235. LPWSTR lpszErrorMsg,
  236. WORD cbErrorMsgMax,
  237. WORD* pcbErrorMsg);
  238. RETCODE INSTAPI
  239. SQLPostInstallerError (
  240. DWORD fErrorCode,
  241. LPSTR szErrorMsg);
  242. RETCODE INSTAPI
  243. SQLPostInstallerErrorW (
  244. DWORD fErrorCode,
  245. LPWSTR szErrorMsg);
  246. BOOL INSTAPI
  247. SQLInstallTranslatorEx (
  248. LPCSTR lpszTranslator,
  249. LPCSTR lpszPathIn,
  250. LPSTR lpszPathOut,
  251. WORD cbPathOutMax,
  252. WORD* pcbPathOut,
  253. WORD fRequest,
  254. LPDWORD lpdwUsageCount);
  255. BOOL INSTAPI
  256. SQLInstallTranslatorExW (
  257. LPCWSTR lpszTranslator,
  258. LPCWSTR lpszPathIn,
  259. LPWSTR lpszPathOut,
  260. WORD cbPathOutMax,
  261. WORD* pcbPathOut,
  262. WORD fRequest,
  263. LPDWORD lpdwUsageCount);
  264. BOOL INSTAPI
  265. SQLReadFileDSN (
  266. LPCSTR lpszFileName,
  267. LPCSTR lpszAppName,
  268. LPCSTR lpszKeyName,
  269. LPSTR lpszString,
  270. WORD cbString,
  271. WORD* pcbString);
  272. BOOL INSTAPI
  273. SQLReadFileDSNW (
  274. LPCWSTR lpszFileName,
  275. LPCWSTR lpszAppName,
  276. LPCWSTR lpszKeyName,
  277. LPWSTR lpszString,
  278. WORD cbString,
  279. WORD* pcbString);
  280. BOOL INSTAPI
  281. SQLWriteFileDSN (
  282. LPCSTR lpszFileName,
  283. LPCSTR lpszAppName,
  284. LPCSTR lpszKeyName,
  285. LPSTR lpszString);
  286. BOOL INSTAPI
  287. SQLWriteFileDSNW (
  288. LPCWSTR lpszFileName,
  289. LPCWSTR lpszAppName,
  290. LPCWSTR lpszKeyName,
  291. LPWSTR lpszString);
  292. BOOL INSTAPI
  293. SQLSetConfigMode (
  294. UWORD wConfigMode);
  295. BOOL INSTAPI SQLInstallODBC (
  296. HWND hwndParent,
  297. LPCSTR lpszInfFile,
  298. LPCSTR lpszSrcPath,
  299. LPCSTR lpszDrivers);
  300. BOOL INSTAPI SQLInstallODBCW (
  301. HWND hwndParent,
  302. LPCWSTR lpszInfFile,
  303. LPCWSTR lpszSrcPath,
  304. LPCWSTR lpszDrivers);
  305. BOOL INSTAPI SQLManageDataSources (HWND hwndParent);
  306. BOOL INSTAPI SQLCreateDataSource (
  307. HWND hwndParent,
  308. LPCSTR lpszDSN);
  309. BOOL INSTAPI SQLCreateDataSourceW (
  310. HWND hwndParent,
  311. LPCWSTR lpszDSN);
  312. BOOL INSTAPI SQLGetTranslator (
  313. HWND hwnd,
  314. LPSTR lpszName,
  315. WORD cbNameMax,
  316. WORD * pcbNameOut,
  317. LPSTR lpszPath,
  318. WORD cbPathMax,
  319. WORD * pcbPathOut,
  320. DWORD * pvOption);
  321. BOOL INSTAPI SQLGetTranslatorW (
  322. HWND hwnd,
  323. LPWSTR lpszName,
  324. WORD cbNameMax,
  325. WORD * pcbNameOut,
  326. LPWSTR lpszPath,
  327. WORD cbPathMax,
  328. WORD * pcbPathOut,
  329. DWORD * pvOption);
  330. /* Low level APIs
  331. * NOTE: The high-level APIs should always be used. These APIs
  332. * have been left for compatibility.
  333. */
  334. BOOL INSTAPI SQLInstallDriver (
  335. LPCSTR lpszInfFile,
  336. LPCSTR lpszDriver,
  337. LPSTR lpszPath,
  338. WORD cbPathMax,
  339. WORD * pcbPathOut);
  340. BOOL INSTAPI SQLInstallDriverW (
  341. LPCWSTR lpszInfFile,
  342. LPCWSTR lpszDriver,
  343. LPWSTR lpszPath,
  344. WORD cbPathMax,
  345. WORD * pcbPathOut);
  346. BOOL INSTAPI SQLInstallDriverManager (
  347. LPSTR lpszPath,
  348. WORD cbPathMax,
  349. WORD * pcbPathOut);
  350. BOOL INSTAPI SQLInstallDriverManagerW (
  351. LPWSTR lpszPath,
  352. WORD cbPathMax,
  353. WORD * pcbPathOut);
  354. BOOL INSTAPI SQLGetInstalledDrivers (
  355. LPSTR lpszBuf,
  356. WORD cbBufMax,
  357. WORD * pcbBufOut);
  358. BOOL INSTAPI SQLGetInstalledDriversW (
  359. LPWSTR lpszBuf,
  360. WORD cbBufMax,
  361. WORD * pcbBufOut);
  362. BOOL INSTAPI SQLGetAvailableDrivers (
  363. LPCSTR lpszInfFile,
  364. LPSTR lpszBuf,
  365. WORD cbBufMax,
  366. WORD * pcbBufOut);
  367. BOOL INSTAPI SQLGetAvailableDriversW (
  368. LPCWSTR lpszInfFile,
  369. LPWSTR lpszBuf,
  370. WORD cbBufMax,
  371. WORD * pcbBufOut);
  372. BOOL INSTAPI SQLConfigDataSource (
  373. HWND hwndParent,
  374. WORD fRequest,
  375. LPCSTR lpszDriver,
  376. LPCSTR lpszAttributes);
  377. BOOL INSTAPI SQLConfigDataSourceW (
  378. HWND hwndParent,
  379. WORD fRequest,
  380. LPCWSTR lpszDriver,
  381. LPCWSTR lpszAttributes);
  382. BOOL INSTAPI SQLRemoveDefaultDataSource (void);
  383. BOOL INSTAPI SQLWriteDSNToIni (
  384. LPCSTR lpszDSN,
  385. LPCSTR lpszDriver);
  386. BOOL INSTAPI SQLWriteDSNToIniW (
  387. LPCWSTR lpszDSN,
  388. LPCWSTR lpszDriver);
  389. BOOL INSTAPI SQLRemoveDSNFromIni (LPCSTR lpszDSN);
  390. BOOL INSTAPI SQLRemoveDSNFromIniW (LPCWSTR lpszDSN);
  391. BOOL INSTAPI SQLValidDSN (LPCSTR lpszDSN);
  392. BOOL INSTAPI SQLValidDSNW (LPCWSTR lpszDSN);
  393. BOOL INSTAPI SQLWritePrivateProfileString (
  394. LPCSTR lpszSection,
  395. LPCSTR lpszEntry,
  396. LPCSTR lpszString,
  397. LPCSTR lpszFilename);
  398. BOOL INSTAPI SQLWritePrivateProfileStringW (
  399. LPCWSTR lpszSection,
  400. LPCWSTR lpszEntry,
  401. LPCWSTR lpszString,
  402. LPCWSTR lpszFilename);
  403. int INSTAPI SQLGetPrivateProfileString (
  404. LPCSTR lpszSection,
  405. LPCSTR lpszEntry,
  406. LPCSTR lpszDefault,
  407. LPSTR lpszRetBuffer,
  408. int cbRetBuffer,
  409. LPCSTR lpszFilename);
  410. int INSTAPI SQLGetPrivateProfileStringW (
  411. LPCWSTR lpszSection,
  412. LPCWSTR lpszEntry,
  413. LPCWSTR lpszDefault,
  414. LPWSTR lpszRetBuffer,
  415. int cbRetBuffer,
  416. LPCWSTR lpszFilename);
  417. BOOL INSTAPI SQLRemoveDriverManager (LPDWORD lpdwUsageCount);
  418. BOOL INSTAPI SQLInstallTranslator (
  419. LPCSTR lpszInfFile,
  420. LPCSTR lpszTranslator,
  421. LPCSTR lpszPathIn,
  422. LPSTR lpszPathOut,
  423. WORD cbPathOutMax,
  424. WORD * pcbPathOut,
  425. WORD fRequest,
  426. LPDWORD lpdwUsageCount);
  427. BOOL INSTAPI SQLInstallTranslatorW (
  428. LPCWSTR lpszInfFile,
  429. LPCWSTR lpszTranslator,
  430. LPCWSTR lpszPathIn,
  431. LPWSTR lpszPathOut,
  432. WORD cbPathOutMax,
  433. WORD * pcbPathOut,
  434. WORD fRequest,
  435. LPDWORD lpdwUsageCount);
  436. BOOL INSTAPI SQLRemoveTranslator (
  437. LPCSTR lpszTranslator,
  438. LPDWORD lpdwUsageCount);
  439. BOOL INSTAPI SQLRemoveTranslatorW (
  440. LPCWSTR lpszTranslator,
  441. LPDWORD lpdwUsageCount);
  442. BOOL INSTAPI SQLRemoveDriver (
  443. LPCSTR lpszDriver,
  444. BOOL fRemoveDSN,
  445. LPDWORD lpdwUsageCount);
  446. BOOL INSTAPI SQLRemoveDriverW (
  447. LPCWSTR lpszDriver,
  448. BOOL fRemoveDSN,
  449. LPDWORD lpdwUsageCount);
  450. BOOL INSTAPI SQLConfigDriver (
  451. HWND hwndParent,
  452. WORD fRequest,
  453. LPCSTR lpszDriver,
  454. LPCSTR lpszArgs,
  455. LPSTR lpszMsg,
  456. WORD cbMsgMax,
  457. WORD * pcbMsgOut);
  458. BOOL INSTAPI SQLConfigDriverW (
  459. HWND hwndParent,
  460. WORD fRequest,
  461. LPCWSTR lpszDriver,
  462. LPCWSTR lpszArgs,
  463. LPWSTR lpszMsg,
  464. WORD cbMsgMax,
  465. WORD * pcbMsgOut);
  466. /* Driver specific Setup APIs called by installer */
  467. typedef BOOL INSTAPI (*pConfigDSNFunc) (
  468. HWND hwndParent,
  469. WORD fRequest,
  470. LPCSTR lpszDriver,
  471. LPCSTR lpszAttributes);
  472. typedef BOOL INSTAPI (*pConfigDSNWFunc) (
  473. HWND hwndParent,
  474. WORD fRequest,
  475. LPCWSTR lpszDriver,
  476. LPCWSTR lpszAttributes);
  477. typedef BOOL INSTAPI (*pConfigDriverFunc) (
  478. HWND hwndParent,
  479. WORD fRequest,
  480. LPCSTR lpszDriver,
  481. LPCSTR lpszArgs,
  482. LPSTR lpszMsg,
  483. WORD cbMsgMax,
  484. WORD * pcbMsgOut);
  485. typedef BOOL INSTAPI (*pConfigDriverWFunc) (
  486. HWND hwndParent,
  487. WORD fRequest,
  488. LPCWSTR lpszDriver,
  489. LPCWSTR lpszArgs,
  490. LPWSTR lpszMsg,
  491. WORD cbMsgMax,
  492. WORD * pcbMsgOut);
  493. typedef BOOL INSTAPI (*pConfigTranslatorFunc) (
  494. HWND hwndParent,
  495. DWORD *pvOption);
  496. BOOL INSTAPI ConfigDSN (
  497. HWND hwndParent,
  498. WORD fRequest,
  499. LPCSTR lpszDriver,
  500. LPCSTR lpszAttributes);
  501. BOOL INSTAPI ConfigDSNW (
  502. HWND hwndParent,
  503. WORD fRequest,
  504. LPCWSTR lpszDriver,
  505. LPCWSTR lpszAttributes);
  506. BOOL INSTAPI ConfigTranslator (HWND hwndParent,
  507. DWORD * pvOption);
  508. BOOL INSTAPI ConfigDriver (
  509. HWND hwndParent,
  510. WORD fRequest,
  511. LPCSTR lpszDriver,
  512. LPCSTR lpszArgs,
  513. LPSTR lpszMsg,
  514. WORD cbMsgMax,
  515. WORD * pcbMsgOut);
  516. BOOL INSTAPI ConfigDriverW (
  517. HWND hwndParent,
  518. WORD fRequest,
  519. LPCWSTR lpszDriver,
  520. LPCWSTR lpszArgs,
  521. LPWSTR lpszMsg,
  522. WORD cbMsgMax,
  523. WORD * pcbMsgOut);
  524. #ifndef SQL_NOUNICODEMAP
  525. #ifdef UNICODE
  526. #define SQLInstallODBC SQLInstallODBCW
  527. #define SQLCreateDataSource SQLCreateDataSourceW
  528. #define SQLGetTranslator SQLGetTranslatorW
  529. #define SQLInstallDriver SQLInstallDriverW
  530. #define SQLInstallDriverManager SQLInstallDriverManagerW
  531. #define SQLGetInstalledDrivers SQLGetInstalledDriversW
  532. #define SQLGetAvailableDrivers SQLGetAvailableDriversW
  533. #define SQLConfigDataSource SQLConfigDataSourceW
  534. #define SQLWriteDSNToIni SQLWriteDSNToIniW
  535. #define SQLRemoveDSNFromIni SQLRemoveDSNFromIniW
  536. #define SQLValidDSN SQLValidDSNW
  537. #define SQLWritePrivateProfileString SQLWritePrivateProfileStringW
  538. #define SQLGetPrivateProfileString SQLGetPrivateProfileStringW
  539. #define SQLInstallTranslator SQLInstallTranslatorW
  540. #define SQLRemoveTranslator SQLRemoveTranslatorW
  541. #define SQLRemoveDriver SQLRemoveDriverW
  542. #define SQLConfigDriver SQLConfigDriverW
  543. #define SQLInstallerError SQLInstallerErrorW
  544. #define SQLPostInstallerError SQLPostInstallerErrorW
  545. #define SQLReadFileDSN SQLReadFileDSNW
  546. #define SQLWriteFileDSN SQLWriteFileDSNW
  547. #define SQLInstallDriverEx SQLInstallDriverExW
  548. #define SQLInstallTranslatorEx SQLInstallTranslatorExW
  549. #endif /* UNICODE */
  550. #endif /* SQL_NOUNICODEMAP */
  551. #ifdef __cplusplus
  552. }
  553. #endif
  554. #endif /* _ODBCINST_H */