Update ooo320-m1
[ooovba.git] / connectivity / source / inc / odbc / OFunctions.hxx
blob9a6d07c505b4831f95bb3f6b2b56b07088bb4430
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: OFunctions.hxx,v $
10 * $Revision: 1.5 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef _CONNECTIVITY_ODBC_OFUNCTIONS_HXX_
32 #define _CONNECTIVITY_ODBC_OFUNCTIONS_HXX_
34 #include "odbc/OFunctiondefs.hxx"
35 #include <rtl/ustring.hxx>
36 #include <osl/module.h>
38 namespace connectivity
41 // sal_Bool LoadFunctions(oslModule pODBCso, sal_Bool _bDS=sal_True);
42 // sal_Bool LoadLibrary_ODBC3(::rtl::OUString &_rPath);
43 // sal_Bool LoadLibrary_ADABAS(::rtl::OUString &_rPath);
45 // Connecting to a data source
46 typedef SQLRETURN (SQL_API *T3SQLAllocHandle) (SQLSMALLINT HandleType,SQLHANDLE InputHandle,SQLHANDLE * OutputHandlePtr);
48 #define N3SQLAllocHandle(a,b,c) (*(T3SQLAllocHandle)getOdbcFunction(ODBC3SQLAllocHandle))(a,b,c)
50 typedef SQLRETURN (SQL_API *T3SQLConnect) (SQLHDBC ConnectionHandle,SQLCHAR *ServerName,SQLSMALLINT NameLength1,SQLCHAR *UserName,SQLSMALLINT NameLength2,SQLCHAR *Authentication,SQLSMALLINT NameLength3);
52 #define N3SQLConnect(a,b,c,d,e,f,g) (*(T3SQLConnect)getOdbcFunction(ODBC3SQLConnect))(a,b,c,d,e,f,g)
54 typedef SQLRETURN (SQL_API *T3SQLDriverConnect) ( SQLHDBC ConnectionHandle,
55 HWND WindowHandle,
56 SQLCHAR * InConnectionString,
57 SQLSMALLINT StringLength1,
58 SQLCHAR * OutConnectionString,
59 SQLSMALLINT BufferLength,
60 SQLSMALLINT * StringLength2Ptr,
61 SQLUSMALLINT DriverCompletion);
63 #define N3SQLDriverConnect(a,b,c,d,e,f,g,h) (*(T3SQLDriverConnect)getOdbcFunction(ODBC3SQLDriverConnect))(a,b,c,d,e,f,g,h)
65 typedef SQLRETURN (SQL_API *T3SQLBrowseConnect) ( SQLHDBC ConnectionHandle,
66 SQLCHAR * InConnectionString,
67 SQLSMALLINT StringLength1,
68 SQLCHAR * OutConnectionString,
69 SQLSMALLINT BufferLength,
70 SQLSMALLINT * StringLength2Ptr);
72 #define N3SQLBrowseConnect(a,b,c,d,e,f) (*(T3SQLBrowseConnect)getOdbcFunction(ODBC3SQLBrowseConnect))(a,b,c,d,e,f)
74 // Obtaining information about a driver and data source
75 typedef SQLRETURN (SQL_API *T3SQLDataSources) ( SQLHENV EnvironmentHandle,
76 SQLUSMALLINT Direction,
77 SQLCHAR * ServerName,
78 SQLSMALLINT BufferLength1,
79 SQLSMALLINT * NameLength1Ptr,
80 SQLCHAR * Description,
81 SQLSMALLINT BufferLength2,
82 SQLSMALLINT * NameLength2Ptr);
84 #define N3SQLDataSources(a,b,c,d,e,f,g,h) (*(T3SQLDataSources)getOdbcFunction(ODBC3SQLDataSources))(a,b,c,d,e,f,g,h)
86 typedef SQLRETURN (SQL_API *T3SQLDrivers) ( SQLHENV EnvironmentHandle,
87 SQLUSMALLINT Direction,
88 SQLCHAR * DriverDescription,
89 SQLSMALLINT BufferLength1,
90 SQLSMALLINT * DescriptionLengthPtr,
91 SQLCHAR * DriverAttributes,
92 SQLSMALLINT BufferLength2,
93 SQLSMALLINT * AttributesLengthPtr);
95 #define N3SQLDrivers(a,b,c,d,e,f,g,h) (*(T3SQLDrivers)getOdbcFunction(ODBC3SQLDrivers))(a,b,c,d,e,f,g,h)
97 typedef SQLRETURN (SQL_API *T3SQLGetInfo) ( SQLHDBC ConnectionHandle,
98 SQLUSMALLINT InfoType,
99 SQLPOINTER InfoValuePtr,
100 SQLSMALLINT BufferLength,
101 SQLSMALLINT * StringLengthPtr);
103 #define N3SQLGetInfo(a,b,c,d,e) (*(T3SQLGetInfo)getOdbcFunction(ODBC3SQLGetInfo))(a,b,c,d,e)
105 typedef SQLRETURN (SQL_API *T3SQLGetFunctions) (SQLHDBC ConnectionHandle,
106 SQLUSMALLINT FunctionId,
107 SQLUSMALLINT * SupportedPtr);
109 #define N3SQLGetFunctions(a,b,c) (*(T3SQLGetFunctions)getOdbcFunction(ODBC3SQLGetFunctions))(a,b,c)
111 typedef SQLRETURN (SQL_API *T3SQLGetTypeInfo) ( SQLHSTMT StatementHandle,
112 SQLSMALLINT DataType);
114 #define N3SQLGetTypeInfo(a,b) (*(T3SQLGetTypeInfo)getOdbcFunction(ODBC3SQLGetTypeInfo))(a,b)
116 // Setting and retrieving driver attributes
117 typedef SQLRETURN (SQL_API *T3SQLSetConnectAttr)(SQLHDBC ConnectionHandle,
118 SQLINTEGER Attribute,
119 SQLPOINTER ValuePtr,
120 SQLINTEGER StringLength);
122 #define N3SQLSetConnectAttr(a,b,c,d) (*(T3SQLSetConnectAttr)getOdbcFunction(ODBC3SQLSetConnectAttr))(a,b,c,d)
124 typedef SQLRETURN (SQL_API *T3SQLGetConnectAttr) (SQLHDBC ConnectionHandle,
125 SQLINTEGER Attribute,
126 SQLPOINTER ValuePtr,
127 SQLINTEGER BufferLength,
128 SQLINTEGER* StringLength);
130 #define N3SQLGetConnectAttr(a,b,c,d,e) (*(T3SQLGetConnectAttr)getOdbcFunction(ODBC3SQLGetConnectAttr))(a,b,c,d,e)
133 typedef SQLRETURN (SQL_API *T3SQLSetEnvAttr) ( SQLHENV EnvironmentHandle,
134 SQLINTEGER Attribute,
135 SQLPOINTER ValuePtr,
136 SQLINTEGER StringLength);
138 #define N3SQLSetEnvAttr(a,b,c,d) (*(T3SQLSetEnvAttr)getOdbcFunction(ODBC3SQLSetEnvAttr))(a,b,c,d)
140 typedef SQLRETURN (SQL_API *T3SQLGetEnvAttr) ( SQLHENV EnvironmentHandle,
141 SQLINTEGER Attribute,
142 SQLPOINTER ValuePtr,
143 SQLINTEGER BufferLength,
144 SQLINTEGER* StringLength);
146 #define N3SQLGetEnvAttr(a,b,c,d,e) (*(T3SQLGetEnvAttr)getOdbcFunction(ODBC3SQLGetEnvAttr))(a,b,c,d,e)
149 typedef SQLRETURN (SQL_API *T3SQLSetStmtAttr) ( SQLHSTMT StatementHandle,
150 SQLINTEGER Attribute,
151 SQLPOINTER ValuePtr,
152 SQLINTEGER StringLength);
154 #define N3SQLSetStmtAttr(a,b,c,d) (*(T3SQLSetStmtAttr)getOdbcFunction(ODBC3SQLSetStmtAttr))(a,b,c,d)
156 typedef SQLRETURN (SQL_API *T3SQLGetStmtAttr) ( SQLHSTMT StatementHandle,
157 SQLINTEGER Attribute,
158 SQLPOINTER ValuePtr,
159 SQLINTEGER BufferLength,
160 SQLINTEGER* StringLength);
162 #define N3SQLGetStmtAttr(a,b,c,d,e) (*(T3SQLGetStmtAttr)getOdbcFunction(ODBC3SQLGetStmtAttr))(a,b,c,d,e)
164 // Setting and retrieving descriptor fields
165 /*typedef SQLRETURN (SQL_API *T3SQLSetDescField) (SQLHDESC DescriptorHandle,
166 SQLSMALLINT RecNumber,
167 SQLSMALLINT FieldIdentifier,
168 SQLPOINTER ValuePtr,
169 SQLINTEGER BufferLength);
171 #define N3SQLSetDescField(a,b,c,d,e) (*(T3SQLSetDescField)getOdbcFunction(ODBC3SQLSetDescField))(a,b,c,d,e)
173 typedef SQLRETURN (SQL_API *T3SQLGetDescField) ( SQLHDESC DescriptorHandle,
174 SQLSMALLINT RecNumber,
175 SQLSMALLINT FieldIdentifier,
176 SQLPOINTER ValuePtr,
177 SQLINTEGER BufferLength,
178 SQLINTEGER * StringLengthPtr);
180 #define N3SQLGetDescField(a,b,c,d,e,f) (*(T3SQLGetDescField)getOdbcFunction(ODBC3SQLGetDescField))(a,b,c,d,e,f)
183 typedef SQLRETURN (SQL_API *T3SQLGetDescRec) ( SQLHDESC DescriptorHandle,
184 SQLSMALLINT RecNumber,
185 SQLCHAR * Name,
186 SQLSMALLINT BufferLength,
187 SQLSMALLINT * StringLengthPtr,
188 SQLSMALLINT * TypePtr,
189 SQLSMALLINT * SubTypePtr,
190 SQLLEN * LengthPtr,
191 SQLSMALLINT * PrecisionPtr,
192 SQLSMALLINT * ScalePtr,
193 SQLSMALLINT * NullablePtr);
195 #define N3SQLGetDescRec(a,b,c,d,e,f,g,h,i,j,k) (*(T3SQLGetDescRec)getOdbcFunction(ODBC3SQLGetDescRec))(a,b,c,d,e,f,g,h,i,j,k)
198 typedef SQLRETURN (SQL_API *T3SQLSetDescRec) ( SQLHDESC DescriptorHandle,
199 SQLSMALLINT RecNumber,
200 SQLSMALLINT Type,
201 SQLSMALLINT SubType,
202 SQLINTEGER Length,
203 SQLSMALLINT Precision,
204 SQLSMALLINT Scale,
205 SQLPOINTER DataPtr,
206 SQLLEN * StringLengthPtr,
207 SQLLEN * IndicatorPtr);
209 #define N3SQLSetDescRec(a,b,c,d,e,f,g,h,i,j) (*(T3SQLSetDescRec)getOdbcFunction(ODBC3SQLSetDescRec))(a,b,c,d,e,f,g,h,i,j)
212 // Preparing SQL requests
213 typedef SQLRETURN (SQL_API *T3SQLPrepare) ( SQLHSTMT StatementHandle,
214 SQLCHAR * StatementText,
215 SQLINTEGER TextLength);
217 #define N3SQLPrepare(a,b,c) (*(T3SQLPrepare)getOdbcFunction(ODBC3SQLPrepare))(a,b,c)
219 typedef SQLRETURN (SQL_API *T3SQLBindParameter) (SQLHSTMT StatementHandle,
220 SQLUSMALLINT ParameterNumber,
221 SQLSMALLINT InputOutputType,
222 SQLSMALLINT ValueType,
223 SQLSMALLINT ParameterType,
224 SQLULEN ColumnSize,
225 SQLSMALLINT DecimalDigits,
226 SQLPOINTER ParameterValuePtr,
227 SQLLEN BufferLength,
228 SQLLEN * StrLen_or_IndPtr);
230 #define N3SQLBindParameter(a,b,c,d,e,f,g,h,i,j) (*(T3SQLBindParameter)getOdbcFunction(ODBC3SQLBindParameter))(a,b,c,d,e,f,g,h,i,j)
232 /*typedef SQLRETURN (SQL_API *T3SQLGetCursorName) (SQLHSTMT StatementHandle,
233 SQLCHAR * CursorName,
234 SQLSMALLINT BufferLength,
235 SQLSMALLINT * NameLengthPtr);
237 #define N3SQLGetCursorName(a,b,c,d) (*(T3SQLGetCursorName)getOdbcFunction(ODBC3SQLGetCursorName))(a,b,c,d)
240 typedef SQLRETURN (SQL_API *T3SQLSetCursorName) (SQLHSTMT StatementHandle,
241 SQLCHAR * CursorName,
242 SQLSMALLINT NameLength);
244 #define N3SQLSetCursorName(a,b,c) (*(T3SQLSetCursorName)getOdbcFunction(ODBC3SQLSetCursorName))(a,b,c)
246 // Submitting requests
247 typedef SQLRETURN (SQL_API *T3SQLExecute) ( SQLHSTMT StatementHandle);
249 #define N3SQLExecute(a) (*(T3SQLExecute)getOdbcFunction(ODBC3SQLExecute))(a)
251 typedef SQLRETURN (SQL_API *T3SQLExecDirect) ( SQLHSTMT StatementHandle,
252 SQLCHAR * StatementText,
253 SQLINTEGER TextLength);
255 #define N3SQLExecDirect(a,b,c) (*(T3SQLExecDirect)getOdbcFunction(ODBC3SQLExecDirect))(a,b,c)
257 /*typedef SQLRETURN (SQL_API *T3SQLNativeSql) ( SQLHDBC ConnectionHandle,
258 SQLCHAR * InStatementText,
259 SQLINTEGER TextLength1,
260 SQLCHAR * utStatementText,
261 SQLINTEGER BufferLength,
262 SQLINTEGER * TextLength2Ptr);
264 #define N3SQLNativeSql(a,b,c,d,e,f) (*(T3SQLNativeSql)getOdbcFunction(ODBC3SQLNativeSql))(a,b,c,d,e,f)*/
266 typedef SQLRETURN (SQL_API *T3SQLDescribeParam) (SQLHSTMT StatementHandle,
267 SQLUSMALLINT ParameterNumber,
268 SQLSMALLINT * DataTypePtr,
269 SQLULEN * ParameterSizePtr,
270 SQLSMALLINT * DecimalDigitsPtr,
271 SQLSMALLINT * NullablePtr);
273 #define N3SQLDescribeParam(a,b,c,d,e,f) (*(T3SQLDescribeParam)getOdbcFunction(ODBC3SQLDescribeParam))(a,b,c,d,e,f)
275 typedef SQLRETURN (SQL_API *T3SQLNumParams) ( SQLHSTMT StatementHandle,
276 SQLSMALLINT * ParameterCountPtr);
278 #define N3SQLNumParams(a,b) (*(T3SQLNumParams)getOdbcFunction(ODBC3SQLNumParams))(a,b)
280 typedef SQLRETURN (SQL_API *T3SQLParamData) ( SQLHSTMT StatementHandle,
281 SQLPOINTER * ValuePtrPtr);
283 #define N3SQLParamData(a,b) (*(T3SQLParamData)getOdbcFunction(ODBC3SQLParamData))(a,b)
285 typedef SQLRETURN (SQL_API *T3SQLPutData) ( SQLHSTMT StatementHandle,
286 SQLPOINTER DataPtr,
287 SQLLEN StrLen_or_Ind);
289 #define N3SQLPutData(a,b,c) (*(T3SQLPutData)getOdbcFunction(ODBC3SQLPutData))(a,b,c)
291 // Retrieving results and information about results
292 typedef SQLRETURN (SQL_API *T3SQLRowCount) ( SQLHSTMT StatementHandle,
293 SQLLEN * RowCountPtr);
295 #define N3SQLRowCount(a,b) (*(T3SQLRowCount)getOdbcFunction(ODBC3SQLRowCount))(a,b)
297 typedef SQLRETURN (SQL_API *T3SQLNumResultCols) (SQLHSTMT StatementHandle,
298 SQLSMALLINT * ColumnCountPtr);
300 #define N3SQLNumResultCols(a,b) (*(T3SQLNumResultCols)getOdbcFunction(ODBC3SQLNumResultCols))(a,b)
302 typedef SQLRETURN (SQL_API *T3SQLDescribeCol) ( SQLHSTMT StatementHandle,
303 SQLUSMALLINT ColumnNumber,
304 SQLCHAR * ColumnName,
305 SQLSMALLINT BufferLength,
306 SQLSMALLINT * NameLengthPtr,
307 SQLSMALLINT * DataTypePtr,
308 SQLULEN * ColumnSizePtr,
309 SQLSMALLINT * DecimalDigitsPtr,
310 SQLSMALLINT * NullablePtr);
312 #define N3SQLDescribeCol(a,b,c,d,e,f,g,h,i) (*(T3SQLDescribeCol)getOdbcFunction(ODBC3SQLDescribeCol))(a,b,c,d,e,f,g,h,i)
314 typedef SQLRETURN (SQL_API *T3SQLColAttribute) (SQLHSTMT StatementHandle,
315 SQLUSMALLINT ColumnNumber,
316 SQLUSMALLINT FieldIdentifier,
317 SQLPOINTER CharacterAttributePtr,
318 SQLSMALLINT BufferLength,
319 SQLSMALLINT * StringLengthPtr,
320 SQLLEN * NumericAttributePtr);
322 #define N3SQLColAttribute(a,b,c,d,e,f,g) (*(T3SQLColAttribute)getOdbcFunction(ODBC3SQLColAttribute))(a,b,c,d,e,f,g)
324 typedef SQLRETURN (SQL_API *T3SQLBindCol) ( SQLHSTMT StatementHandle,
325 SQLUSMALLINT ColumnNumber,
326 SQLSMALLINT TargetType,
327 SQLPOINTER TargetValuePtr,
328 SQLLEN BufferLength,
329 SQLLEN * StrLen_or_IndPtr);
331 #define N3SQLBindCol(a,b,c,d,e,f) (*(T3SQLBindCol)getOdbcFunction(ODBC3SQLBindCol))(a,b,c,d,e,f)
333 typedef SQLRETURN (SQL_API *T3SQLFetch) ( SQLHSTMT StatementHandle);
335 #define N3SQLFetch(a) (*(T3SQLFetch)getOdbcFunction(ODBC3SQLFetch))(a)
337 typedef SQLRETURN (SQL_API *T3SQLFetchScroll) ( SQLHSTMT StatementHandle,
338 SQLSMALLINT FetchOrientation,
339 SQLLEN FetchOffset);
341 #define N3SQLFetchScroll(a,b,c) (*(T3SQLFetchScroll)getOdbcFunction(ODBC3SQLFetchScroll))(a,b,c)
343 typedef SQLRETURN (SQL_API *T3SQLGetData) ( SQLHSTMT StatementHandle,
344 SQLUSMALLINT ColumnNumber,
345 SQLSMALLINT TargetType,
346 SQLPOINTER TargetValuePtr,
347 SQLLEN BufferLength,
348 SQLLEN * StrLen_or_IndPtr);
350 #define N3SQLGetData(a,b,c,d,e,f) (*(T3SQLGetData)getOdbcFunction(ODBC3SQLGetData))(a,b,c,d,e,f)
352 typedef SQLRETURN (SQL_API *T3SQLSetPos) ( SQLHSTMT StatementHandle,
353 SQLSETPOSIROW RowNumber,
354 SQLUSMALLINT Operation,
355 SQLUSMALLINT LockType);
357 #define N3SQLSetPos(a,b,c,d) (*(T3SQLSetPos)getOdbcFunction(ODBC3SQLSetPos))(a,b,c,d)
359 typedef SQLRETURN (SQL_API *T3SQLBulkOperations) ( SQLHSTMT StatementHandle,
360 SQLSMALLINT Operation);
362 #define N3SQLBulkOperations(a,b) (*(T3SQLBulkOperations)getOdbcFunction(ODBC3SQLBulkOperations))(a,b)
364 typedef SQLRETURN (SQL_API *T3SQLMoreResults) ( SQLHSTMT StatementHandle);
366 #define N3SQLMoreResults(a) (*(T3SQLMoreResults)getOdbcFunction(ODBC3SQLMoreResults))(a)
368 /*typedef SQLRETURN (SQL_API *T3SQLGetDiagField) (SQLSMALLINT HandleType,
369 SQLHANDLE Handle,
370 SQLSMALLINT RecNumber,
371 SQLSMALLINT DiagIdentifier,
372 SQLPOINTER DiagInfoPtr,
373 SQLSMALLINT BufferLength,
374 SQLSMALLINT * StringLengthPtr);
376 #define N3SQLGetDiagField(a,b,c,d,e,f,g) (*(T3SQLGetDiagField)getOdbcFunction(ODBC3SQLGetDiagField))(a,b,c,d,e,f,g)*/
378 typedef SQLRETURN (SQL_API *T3SQLGetDiagRec) ( SQLSMALLINT HandleType,
379 SQLHANDLE Handle,
380 SQLSMALLINT RecNumber,
381 SQLCHAR * Sqlstate,
382 SQLINTEGER * NativeErrorPtr,
383 SQLCHAR * MessageText,
384 SQLSMALLINT BufferLength,
385 SQLSMALLINT * TextLengthPtr);
388 #define N3SQLGetDiagRec(a,b,c,d,e,f,g,h) (*(T3SQLGetDiagRec)getOdbcFunction(ODBC3SQLGetDiagRec))(a,b,c,d,e,f,g,h)
390 // Obtaining information about the data source's system tables (catalog functions)
391 typedef SQLRETURN (SQL_API *T3SQLColumnPrivileges) (SQLHSTMT StatementHandle,
392 SQLCHAR * CatalogName,
393 SQLSMALLINT NameLength1,
394 SQLCHAR * SchemaName,
395 SQLSMALLINT NameLength2,
396 SQLCHAR * TableName,
397 SQLSMALLINT NameLength3,
398 SQLCHAR * ColumnName,
399 SQLSMALLINT NameLength4);
401 #define N3SQLColumnPrivileges(a,b,c,d,e,f,g,h,i) (*(T3SQLColumnPrivileges)getOdbcFunction(ODBC3SQLColumnPrivileges))(a,b,c,d,e,f,g,h,i)
403 typedef SQLRETURN (SQL_API *T3SQLColumns) ( SQLHSTMT StatementHandle,
404 SQLCHAR * CatalogName,
405 SQLSMALLINT NameLength1,
406 SQLCHAR * SchemaName,
407 SQLSMALLINT NameLength2,
408 SQLCHAR * TableName,
409 SQLSMALLINT NameLength3,
410 SQLCHAR * ColumnName,
411 SQLSMALLINT NameLength4);
413 #define N3SQLColumns(a,b,c,d,e,f,g,h,i) (*(T3SQLColumns)getOdbcFunction(ODBC3SQLColumns))(a,b,c,d,e,f,g,h,i)
415 typedef SQLRETURN (SQL_API *T3SQLForeignKeys) ( SQLHSTMT StatementHandle,
416 SQLCHAR * PKCatalogName,
417 SQLSMALLINT NameLength1,
418 SQLCHAR * PKSchemaName,
419 SQLSMALLINT NameLength2,
420 SQLCHAR * PKTableName,
421 SQLSMALLINT NameLength3,
422 SQLCHAR * FKCatalogName,
423 SQLSMALLINT NameLength4,
424 SQLCHAR * FKSchemaName,
425 SQLSMALLINT NameLength5,
426 SQLCHAR * FKTableName,
427 SQLSMALLINT NameLength6);
429 #define N3SQLForeignKeys(a,b,c,d,e,f,g,h,i,j,k,l,m) (*(T3SQLForeignKeys)getOdbcFunction(ODBC3SQLForeignKeys))(a,b,c,d,e,f,g,h,i,j,k,l,m)
431 typedef SQLRETURN (SQL_API *T3SQLPrimaryKeys) ( SQLHSTMT StatementHandle,
432 SQLCHAR * CatalogName,
433 SQLSMALLINT NameLength1,
434 SQLCHAR * SchemaName,
435 SQLSMALLINT NameLength2,
436 SQLCHAR * TableName,
437 SQLSMALLINT NameLength3);
439 #define N3SQLPrimaryKeys(a,b,c,d,e,f,g) (*(T3SQLPrimaryKeys)getOdbcFunction(ODBC3SQLPrimaryKeys))(a,b,c,d,e,f,g)
441 typedef SQLRETURN (SQL_API *T3SQLProcedureColumns) (SQLHSTMT StatementHandle,
442 SQLCHAR * CatalogName,
443 SQLSMALLINT NameLength1,
444 SQLCHAR * SchemaName,
445 SQLSMALLINT NameLength2,
446 SQLCHAR * ProcName,
447 SQLSMALLINT NameLength3,
448 SQLCHAR * ColumnName,
449 SQLSMALLINT NameLength4);
451 #define N3SQLProcedureColumns(a,b,c,d,e,f,g,h,i) (*(T3SQLProcedureColumns)getOdbcFunction(ODBC3SQLProcedureColumns))(a,b,c,d,e,f,g,h,i)
453 typedef SQLRETURN (SQL_API *T3SQLProcedures) ( SQLHSTMT StatementHandle,
454 SQLCHAR * CatalogName,
455 SQLSMALLINT NameLength1,
456 SQLCHAR * SchemaName,
457 SQLSMALLINT NameLength2,
458 SQLCHAR * ProcName,
459 SQLSMALLINT NameLength3);
461 #define N3SQLProcedures(a,b,c,d,e,f,g) (*(T3SQLProcedures)getOdbcFunction(ODBC3SQLProcedures))(a,b,c,d,e,f,g)
463 typedef SQLRETURN (SQL_API *T3SQLSpecialColumns) (SQLHSTMT StatementHandle,
464 SQLUSMALLINT IdentifierType,
465 SQLCHAR * CatalogName,
466 SQLSMALLINT NameLength1,
467 SQLCHAR * SchemaName,
468 SQLSMALLINT NameLength2,
469 SQLCHAR * TableName,
470 SQLSMALLINT NameLength3,
471 SQLUSMALLINT Scope,
472 SQLUSMALLINT Nullable);
474 #define N3SQLSpecialColumns(a,b,c,d,e,f,g,h,i,j) (*(T3SQLSpecialColumns)getOdbcFunction(ODBC3SQLSpecialColumns))(a,b,c,d,e,f,g,h,i,j)
476 typedef SQLRETURN (SQL_API *T3SQLStatistics) ( SQLHSTMT StatementHandle,
477 SQLCHAR * CatalogName,
478 SQLSMALLINT NameLength1,
479 SQLCHAR * SchemaName,
480 SQLSMALLINT NameLength2,
481 SQLCHAR * TableName,
482 SQLSMALLINT NameLength3,
483 SQLUSMALLINT Unique,
484 SQLUSMALLINT Reserved);
486 #define N3SQLStatistics(a,b,c,d,e,f,g,h,i) (*(T3SQLStatistics)getOdbcFunction(ODBC3SQLStatistics))(a,b,c,d,e,f,g,h,i)
488 typedef SQLRETURN (SQL_API *T3SQLTablePrivileges) (SQLHSTMT StatementHandle,
489 SQLCHAR * CatalogName,
490 SQLSMALLINT NameLength1,
491 SQLCHAR * SchemaName,
492 SQLSMALLINT NameLength2,
493 SQLCHAR * TableName,
494 SQLSMALLINT NameLength3);
496 #define N3SQLTablePrivileges(a,b,c,d,e,f,g) (*(T3SQLTablePrivileges)getOdbcFunction(ODBC3SQLTablePrivileges))(a,b,c,d,e,f,g)
498 typedef SQLRETURN (SQL_API *T3SQLTables) ( SQLHSTMT StatementHandle,
499 SQLCHAR * CatalogName,
500 SQLSMALLINT NameLength1,
501 SQLCHAR * SchemaName,
502 SQLSMALLINT NameLength2,
503 SQLCHAR * TableName,
504 SQLSMALLINT NameLength3,
505 SQLCHAR * TableType,
506 SQLSMALLINT NameLength4);
508 #define N3SQLTables(a,b,c,d,e,f,g,h,i) (*(T3SQLTables)getOdbcFunction(ODBC3SQLTables))(a,b,c,d,e,f,g,h,i)
510 // Terminating a statement
511 typedef SQLRETURN (SQL_API *T3SQLFreeStmt) ( SQLHSTMT StatementHandle,
512 SQLUSMALLINT Option);
514 #define N3SQLFreeStmt(a,b) (*(T3SQLFreeStmt)getOdbcFunction(ODBC3SQLFreeStmt))(a,b)
516 typedef SQLRETURN (SQL_API *T3SQLCloseCursor) (SQLHSTMT StatementHandle);
518 #define N3SQLCloseCursor(a) (*(T3SQLCloseCursor)getOdbcFunction(ODBC3SQLCloseCursor))(a)
520 typedef SQLRETURN (SQL_API *T3SQLCancel) ( SQLHSTMT StatementHandle);
522 #define N3SQLCancel(a) (*(T3SQLCancel)getOdbcFunction(ODBC3SQLCancel))(a)
524 typedef SQLRETURN (SQL_API *T3SQLEndTran) ( SQLSMALLINT HandleType,
525 SQLHANDLE Handle,
526 SQLSMALLINT CompletionType);
528 #define N3SQLEndTran(a,b,c) (*(T3SQLEndTran)getOdbcFunction(ODBC3SQLEndTran))(a,b,c)
530 // Terminating a connection
531 typedef SQLRETURN (SQL_API *T3SQLDisconnect) (SQLHDBC ConnectionHandle);
533 #define N3SQLDisconnect(a) (*(T3SQLDisconnect)getOdbcFunction(ODBC3SQLDisconnect))(a)
535 typedef SQLRETURN (SQL_API *T3SQLFreeHandle) (SQLSMALLINT HandleType,
536 SQLHANDLE Handle);
538 #define N3SQLFreeHandle(a,b) (*(T3SQLFreeHandle)getOdbcFunction(ODBC3SQLFreeHandle))(a,b)
540 typedef SQLRETURN (SQL_API *T3SQLGetCursorName) ( SQLHSTMT StatementHandle,
541 SQLCHAR * CursorName,
542 SQLSMALLINT BufferLength,
543 SQLSMALLINT* NameLength2);
545 #define N3SQLGetCursorName(a,b,c,d) (*(T3SQLGetCursorName)getOdbcFunction(ODBC3SQLGetCursorName))(a,b,c,d)
547 typedef SQLRETURN (SQL_API *T3SQLNativeSql) ( SQLHSTMT ConnectionHandle,
548 SQLCHAR * InStatementText,
549 SQLINTEGER TextLength1,
550 SQLCHAR * OutStatementText,
551 SQLINTEGER BufferLength,
552 SQLINTEGER * TextLength2Ptr);
554 #define N3SQLNativeSql(a,b,c,d,e,f) (*(T3SQLNativeSql)getOdbcFunction(ODBC3SQLNativeSql))(a,b,c,d,e,f)
557 #endif // _CONNECTIVITY_ODBC_OFUNCTIONS_HXX_