This is a follow-up to [4424].
Have been advised that the source of the difference in float output between mysqli and pdo_mysql is because emulated prepares means pdo_mysql uses a text protocol (instead of binary) communicating with the mysql server.
IIRC we had to use emulated prepares because we (previously) used a query that binds parameters even for DDL statements. After adding mysqli support, DDL statements instead used Piwik_Exec().
Refreshing my memory...
As previously statement, this should be doable because of the change to use Piwik_Exec() in [1480].
In [it was noted that server-side prepares couldn't take advantage of MySQL's query cache for MySQL 5.0 and early versions of 5.1.x. This would seem to be mitigated by the caching of prepared statements in 3716 and [3717].
wont fix, this issue is not a problem (now that the tests are passing after the quick clean hack), and tricky to modify these core SQL things for a non problem ;)
Thanks for the research though because this helps understand what was going on!
Ok.
But for future reference:
$this->_connection->setAttribute(PDO::ATTR_EMULATE_PREPARES, true);