Skip to Content.
Sympa Menu

freetds - Re: [freetds] [FreeTDS] ERROR: CLI describe error: [unixODBC][Driver Manager]Driver does not support this function

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Frediano Ziglio <freddy77 AT gmail.com>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] [FreeTDS] ERROR: CLI describe error: [unixODBC][Driver Manager]Driver does not support this function
  • Date: Mon, 5 Oct 2009 10:15:45 +0200

2009/10/4 James K. Lowden <jklowden AT freetds.org>:
> stock wrote:
>> i try to create a tmp table and copy record from ms sql 2005 table into
>> the tmp table, it hit ERROR: CLI describe error: [unixODBC][Driver
>> Manager]Driver does not support this function.
>
> This message was snagged by the mailing list software because the
> attachment is over 75 KB.  I released it because it's only slightly too
> big.
>
> Was the problem resolved meanwhile?
>

I looked at the problem but I found no reason for this behavior...
from log unixODBC calls SQLGetFunctions with SQL_API_ALL_FUNCTIONS
instead of SQL_API_ODBC3_ALL_FUNCTIONS. 2.2.15 changed slightly
behavior so I compiled it and used instead of system one but I got
SQLGetFunctions called with SQL_API_ODBC3_ALL_FUNCTIONS, not with
SQL_API_ALL_FUNCTIONS !!
One possible patch should be

Index: src/odbc/odbc.c
===================================================================
RCS file: /cvs/freetds/freetds/src/odbc/odbc.c,v
retrieving revision 1.514
diff -u -1 -0 -r1.514 odbc.c
--- src/odbc/odbc.c 3 Oct 2009 09:19:27 -0000 1.514
+++ src/odbc/odbc.c 5 Oct 2009 07:58:17 -0000
@@ -4756,42 +4756,42 @@
/*
* every api available are contained in a macro
* all these macro begin with API followed by 2 letter
* first letter mean pre ODBC 3 (_) or ODBC 3 (3)
* second letter mean implemented (X) or unimplemented (_)
* You should copy these macro 3 times... not very good
* but works. Perhaps best method is build the bit
array statically
* and then use it but I don't know how to build it...
*/
#undef ODBC_ALL_API
-#undef ODBC_COLATTRIBUTES
+#undef ODBC_COLATTRIBUTE

#if SQL_API_SQLCOLATTRIBUTE != SQL_API_SQLCOLATTRIBUTES
-#define ODBC_COLATTRIBUTES(s) s
+#define ODBC_COLATTRIBUTE(s) s
#else
-#define ODBC_COLATTRIBUTES(s)
+#define ODBC_COLATTRIBUTE(s)
#endif

#define ODBC_ALL_API \
API_X(SQL_API_SQLALLOCCONNECT);\
API_X(SQL_API_SQLALLOCENV);\
API3X(SQL_API_SQLALLOCHANDLE);\
API_X(SQL_API_SQLALLOCSTMT);\
API_X(SQL_API_SQLBINDCOL);\
API_X(SQL_API_SQLBINDPARAM);\
API_X(SQL_API_SQLBINDPARAMETER);\
API__(SQL_API_SQLBROWSECONNECT);\
API3_(SQL_API_SQLBULKOPERATIONS);\
API_X(SQL_API_SQLCANCEL);\
API3X(SQL_API_SQLCLOSECURSOR);\
- API3X(SQL_API_SQLCOLATTRIBUTE);\
- ODBC_COLATTRIBUTES(API_X(SQL_API_SQLCOLATTRIBUTES);)\
+ ODBC_COLATTRIBUTE(API3X(SQL_API_SQLCOLATTRIBUTE);)\
+ API_X(SQL_API_SQLCOLATTRIBUTES);\
API_X(SQL_API_SQLCOLUMNPRIVILEGES);\
API_X(SQL_API_SQLCOLUMNS);\
API_X(SQL_API_SQLCONNECT);\
API3X(SQL_API_SQLCOPYDESC);\
API_X(SQL_API_SQLDESCRIBECOL);\
API__(SQL_API_SQLDESCRIBEPARAM);\
API_X(SQL_API_SQLDISCONNECT);\
API_X(SQL_API_SQLDRIVERCONNECT);\
API3X(SQL_API_SQLENDTRAN);\
API_X(SQL_API_SQLERROR);\

but for me with or without this patch seems to work :( Could you try
if this patch works for you ?

freddy77




Archive powered by MHonArc 2.6.24.

Top of Page