X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/47d67540a017101b3e46abe9ef0f55914d8de37e..1c383dbac927bbcc728365b2f8894a5ce676b19b:/src/common/odbc.cpp diff --git a/src/common/odbc.cpp b/src/common/odbc.cpp index 84b145c36f..103fdda8af 100644 --- a/src/common/odbc.cpp +++ b/src/common/odbc.cpp @@ -2,12 +2,12 @@ // Name: odbc.cpp // Purpose: ODBC implementation // Author: Julian Smart, Olaf Klein (oklein@smallo.ruhr.de), -// Patrick Halke (patrick@zaphod.ruhr.de) -// Modified by: +// Patrick Halke (patrick@zaphod.ruhr.de) +// Modified by: // Created: 04/01/98 // RCS-ID: $Id$ // Copyright: (c) Julian Smart and Markus Holzem -// Licence: wxWindows license +// Licence: wxWindows license ///////////////////////////////////////////////////////////////////////////// #ifdef __GNUG__ @@ -23,7 +23,15 @@ #include "wx/defs.h" -#if wxUSE_ODBC +// this code is old and shouldn't be used - use the new ODBC classes in db.cpp +// and dbtable.cpp instead +#define wxUSE_OLD_ODBC 0 + +#if wxUSE_OLD_ODBC + +#ifdef __VISUALC__ + #pragma warning(disable:4706) // assignment within conditional expression +#endif // VC++ #ifndef WX_PRECOMP #include "wx/utils.h" @@ -439,7 +447,7 @@ float wxDatabase::GetODBCVersionFloat(bool implementation) if (retcode == SQL_ERROR) return 0.0; else - return atof(buf); + return (float)atof(buf); } /* @@ -1827,4 +1835,8 @@ bool wxQueryField::IsDirty(void) { return dirty; } -#endif // wxUSE_ODBC +#ifdef __VISUALC__ + #pragma warning(default:4706) // assignment within conditional expression +#endif // VC++ + +#endif // wxUSE_OLD_ODBC