Bug #61777 [Opn->Fbk]: Cannot bind parameters with pdo_odbc and SQL Server Native Client 11.0
Edit report at https://bugs.php.net/bug.php?id=61777&edit=1
ID: 61777
Updated by: stas@php.net
Reported by: frozen at frozen-solid dot net
Summary: Cannot bind parameters with pdo_odbc and SQL Server
Native Client 11.0
-Status: Open
+Status: Feedback
Type: Bug
Package: PDO ODBC
Operating System: Ubuntu 12.04
PHP Version: 5.3.10
Block user comment: N
Private report: N
New Comment:
Please try using this snapshot:
http://snaps.php.net/php-trunk-latest.tar.gz
For Windows:
http://windows.php.net/snapshots/
Fix for bug #50444 checked in, please see if it also fixes this issue.
Previous Comments:
------------------------------------------------------------------------
[2014-03-17 13:08:49] donald dot sipe at gmail dot com
Are there plans to address this issue in an upcoming php release?
This is a serious issue for those of us that would like to use the native MS SQL Server driver since
that is the best "Enterprise" solution for connecting to SQL Server on Linux.
------------------------------------------------------------------------
[2013-04-04 20:36:40] me at andrewkehrig dot com
I can verify this bug still occurs on php 5.3.19 and php 5.4.6 as well.
php 5.3.19 running on Windows experiences a slightly different version of this problem when talking
to SQL Server via ODBC: bound parameters work, as long as you're not comparing them directly to
date datatype columns (date, timestamp, etc) - if you are, you have to cast them manually from
varchar to date, or if you're using a stored procedure with input parameters you have to set
any date input parameters to varchar and allow the server to infer the datatype conversion when
comparing the input parameter(a varchar holding a date, timestamp, etc) to an actual
date,timestamp,etc column.
------------------------------------------------------------------------
[2013-01-30 00:43:04] paul dot posts at gmail dot com
Can confirm that patches in bug 50444 correct this issue for me as well.
------------------------------------------------------------------------
[2012-10-18 17:05:26] kraven at kraven dot org
I believe this is related to the SQLLEN. PHP bug 5044 has a patch.
MS bug here where developer says its SQLLEN:
http://connect.microsoft.com/SQLServer/feedback/details/737751/cannot-bind-
parameters-with-php-pdo-odbc-and-sql-native-client-11-0
I applied the patches in bug 50444 and now it's working for me.
------------------------------------------------------------------------
[2012-05-15 18:59:11] burnhamrobertp at gmail dot com
Debian Squeeze 2.6.32-5-amd64
PHP 5.3.3 (also reproducible under PHP 5.4.0-3)
The test case and error information are exactly the same.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=61777
--
Edit this bug report at https://bugs.php.net/bug.php?id=61777&edit=1
Thread (10 messages)