ID: 44639
Updated by: uw@php.net
Reported By: jgauld at blueyonder dot co dot uk
Status: Open
Bug Type: PDO related
-Operating System: WinXP
+Operating System: All
-PHP Version: 5.2.10
+PHP Version: Any > 5.1.x
New Comment:
Related reports: http://bugs.php.net/bug.php?id=49651 ,
http://bugs.php.net/49381
Previous Comments:
------------------------------------------------------------------------
[2009-09-22 21:18:23] sjoerd@php.net
The third parameter to bindValue defaults to PDO::PARAM_STR. This is
different than the original bug reporter said, so it must be changed in
the meantime. Because the datatype is PDO::PARAM_STR, the int is cast to
a string and quoted.
It would make sense to use the PHP type to determine the most logical
PDO::PARAM_* type. See also bug #44597, which is essentially the same
problem but with booleans and execute() instead of bindValue().
------------------------------------------------------------------------
[2009-08-17 17:38:15] jani@php.net
But you didn't bother updating the version field. Done now..
------------------------------------------------------------------------
[2009-07-21 00:30:49] whistl0r+php at googlemail dot com
Hi,
this bug is still present in the current PHP version.
Tested with PHP 5.2.10 stable and snapshot on Windows.
MySQL client api: 5.1.35
------------------------------------------------------------------------
[2008-10-21 11:59:03] jgauld at blueyonder dot co dot uk
Tried windows snapshot as suggested (5.2.7RC2-dev), but no joy. Result
is same, ie:
select * from my_table where id>'13'
If it helps, phpinfo() reports:
PDO Driver for MySQL, client library version 5.0.51a
------------------------------------------------------------------------
[2008-07-03 15:17:35] uw@php.net
This is not a driver issue. Its the PDO SQL driver messing up SQL
statements.
------------------------------------------------------------------------
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
http://bugs.php.net/44639
--
Edit this bug report at http://bugs.php.net/?id=44639&edit=1