Skip to Content.
Sympa Menu

freetds - RE: [freetds] RETCODE conflict

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "ZIGLIO, Frediano, VF-IT" <Frediano.Ziglio AT vodafone.com>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: RE: [freetds] RETCODE conflict
  • Date: Wed, 30 Mar 2005 08:39:50 +0200

>
> Has any else run into a typedef conflict running FreeTDS with
> unixODBC
> and trying to include both FreeTDS's sqldb.h (which includes sybdb.h)
> and unixODBC's sqltypes.h? sqltypes.h defines RETCODE as a signed
> short. sybdb.h defines RETCODE as an int. Any suggested
> work arounds?
>
> Frederick N. Brier
> Multideck Corporation
>

Both use typedefs (windows too).

A possible solution can be

#include <sql.h>
#define RETCODE DBRETCODE
#include <sybdb.h>
#undef RETCODE

DBRETCODE ret; // dblib return code
RETCODE rc; // ODBC return code

However I don't find the reason to include both dblib and ODBC...

freddy77




Archive powered by MHonArc 2.6.24.

Top of Page