1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
29 //--------------------------------------------------------------------------
30 #ifndef _CONNECTIVITY_OFUNCTIONDEFS_HXX_
31 #define _CONNECTIVITY_OFUNCTIONDEFS_HXX_
37 #pragma warning(disable:4005)
40 // just to go with calling convention of windows
41 #define SQL_API __stdcall
42 #include <odbc/sqlext.h>
44 #define SQL_API __stdcall
50 #ifndef SQL_C_BOOKMARK
51 #define SQL_C_BOOKMARK SQL_C_ULONG /* BOOKMARK */
54 #ifndef SQL_OPT_TRACE_OFF
55 #define SQL_OPT_TRACE_OFF 0UL
58 #define SDB_ODBC_CHAR UCHAR
62 //--------------------------------------------------------------------------
68 // Stub version: dynamic binding to the DLL at runtime.
69 // odbcstub defines the NSQL... methods used in the sources
70 // as indirect function calls.
71 // odbcimp uses preos2, odbc and postos2 itself.
72 // #include "odbc3imp.hxx"
76 // Currently, we directly use the ODBC DLL from Watcom SQL (via the supplied lib)
84 #define SQL_API __syscall
85 #ifndef SQL_MAX_MESSAGE_LENGTH
86 #define SQL_MAX_MESSAGE_LENGTH MAX_MESSAGE_LENGTH
88 #ifndef SQL_MAX_DSN_LENGTH
89 #define SQL_MAX_DSN_LENGTH MAX_DSN_LENGTH
91 #ifndef SQL_AUTOCOMMIT_ON
92 #define SQL_AUTOCOMMIT_ON 1UL
94 #ifndef SQL_AUTOCOMMIT_OFF
95 #define SQL_AUTOCOMMIT_OFF 0UL
98 #define SQL_FETCH_PRIOR SQL_FETCH_PREV
99 #define SQL_NO_TOTAL (-4)
103 // The ODBC.h from Watcom expects char*, not UCHAR* usually used with ODBC
105 #define SDB_ODBC_CHAR unsigned char
107 #define SDB_ODBC_CHAR char
112 //--------------------------------------------------------------------------
116 // Currently, we directly use the ODBC shared library from Q+E (via the supplied lib)
123 #ifdef SYSTEM_ODBC_HEADERS
126 #include <odbc/sqlext.h>
128 #undef sal_Bool // Is defined in qeodbc.h, but gets redefined by solar.h
130 #define SDB_ODBC_CHAR UCHAR
131 #define SQL_WCHAR (-8)
132 #define SQL_WVARCHAR (-9)
133 #define SQL_WLONGVARCHAR (-10)
134 #define SQL_C_WCHAR SQL_WCHAR
139 //--------------------------------------------------------------------------
142 #define SQL_WCHAR (-8)
145 #define SQL_WVARCHAR (-9)
147 #ifndef SQL_WLONGVARCHAR
148 #define SQL_WLONGVARCHAR (-10)
151 #define SQL_C_WCHAR SQL_WCHAR
155 #define SQL_C_TCHAR SQL_C_WCHAR
157 #define SQL_C_TCHAR SQL_C_CHAR
160 #endif // _CONNECTIVITY_OFUNCTIONDEFS_HXX_
163 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */