Skip to Content.
Sympa Menu

freetds - Re: ODBC in CVS head: SQL_DATETIME?

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: iODBC Maintainer <iodbc AT openlinksw.com>
  • To: TDS Development Group <freetds AT franklin.oit.unc.edu>
  • Subject: Re: ODBC in CVS head: SQL_DATETIME?
  • Date: Sat, 24 Nov 2001 21:59:49 +0100


Hi Steve,

> As of revision 1.2 of src/odbc/odbc.c (which includes a changelog entry
> reading 'fixed SQL_DATE things in ODBC'), this file contains a reference
> to a SQL_DATETIME constant. However, I've been unable to locate this
> macro in either the iODBC headers or the unixodbc 2.0.8 headers, and its
> abence naturally causes compilation of the ODBC driver to fail. I have
> found one reference to SQL_DATETIME in the unixodbc 2.0.11 headers, so
> compilation against unixodbc is possible. But how should this be
> handled so that people who only have iODBC installed can still compile
> this driver?

The current version of iODBC does have this constant. You can download the
latest iODBC version from:

http://www.iodbc.org/

This constant was introduced in ODBC V3 API specification and has been
part of the iODBC source for a long time now. I have successfully compiled
the FreeTDS ODBC driver with iODBC.

> I see SQL_DATE used elsewhere in the source, and SQL_DATE and
> SQL_DATETIME both have the same value in unixodbc 2.0.11. Is it
> acceptable to s/SQL_DATETIME/SQL_DATE/ on the source and call it good,
> or is this just a coincidence?
>

As your driver is currently written against the ODBC 2.0 specification, i
recommend you use the SQL_DATE constant. You may also want to compile with
-DODBCVER=0x0200 to make sure you do not use ODBC 3 constants by mistake.


Best regards,

Patrick

--
Patrick van Kleef Email : iodbc AT openlinksw.com
Maintainer iODBC Web : http://www.iodbc.org/
OpenLink Software

Universal Data Access & Data Integration Technology Providers






Archive powered by MHonArc 2.6.24.

Top of Page