|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-10-08 18:51 UTC] iliaa@php.net
[2007-10-08 21:31 UTC] salac dot r at gmail dot com
[2007-10-12 18:48 UTC] mj@php.net
[2007-10-19 21:05 UTC] salac dot r at gmail dot com
[2007-10-19 21:07 UTC] salac dot r at gmail dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 23 08:00:01 2025 UTC |
Description: ------------ When I'm using ATTR_EMULATE_PREPARES set to true, function rowCount returns bad result (0). I think that it's quite strange because without ATTR_EMULATE_PREPARES it returns god values. Reproduce code: --------------- $dbh = new PDO('mysql:host=localhost;dbname=test', $user, $pass, array( PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true, PDO::ATTR_EMULATE_PREPARES => true) ); $result=$dbh->query("SELECT * FROM Table"); echo "rows = ".$result->rowCount(); Expected result: ---------------- rows = 7 //number of rows in Table Actual result: -------------- rows = 0