#20086 [Opn->Csd]: SQLDriverConnect supported by win32
| From: | kalowsky@php.net | Date: | Thu, 31 Oct 2002 02:57:30 +0000 |
| Subject: | #20086 [Opn->Csd]: SQLDriverConnect supported by win32 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-23755@lists.php.net to get a copy of this message | ||
ID: 20086
Updated by: kalowsky@php.net
Reported By: john@johnandlouise.com
-Status: Open
+Status: Closed
Bug Type: ODBC related
Operating System: W2K
PHP Version: 4CVS-2002-10-25
New Comment:
PHP is now your DSN-less friend. Please test a snapshot and make sure
this is working properly for you.
Previous Comments:
------------------------------------------------------------------------
[2002-10-28 11:38:27] john@johnandlouise.com
diff is now my new friend. Is this right? :-)
2110c2110
< #if defined(HAVE_EMPRESS) || defined(HAVE_UNIXODBC)
---
> #if defined(HAVE_EMPRESS) || defined(HAVE_UNIXODBC) ||
defined(PHP_WIN32)
2133c2133
< rc = SQLDriverConnect((*conn)->hdbc, NULL, ldb, strlen(ldb),
dsnbuf, 300,
---
> rc = SQLDriverConnect((*conn)->hdbc, NULL, ldb,
(short)strlen(ldb), dsnbuf, 300,
The (short) typecast is to prevent a warning in win32 - don't know if
it will have issues with other platforms. Now using PHP_WIN32 not WIN32
for consistency with other code.
------------------------------------------------------------------------
[2002-10-27 19:46:08] kalowsky@php.net
Unified diffs are your and my friends. Can you please provide one!
------------------------------------------------------------------------
[2002-10-25 09:45:46] john@johnandlouise.com
In ext/odbc/php_odbc.php dsn-less connections are only supported for
empress and unixodbc. Windows also supports this connection method.
Changing the line:
#if defined(HAVE_EMPRESS) || defined(HAVE_UNIXODBC)
to:
#if defined(HAVE_EMPRESS) || defined(HAVE_UNIXODBC) || defined(WIN32)
enables dsn-less connections under windows.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=20086&edit=1