ID: 47297 User updated by: matteo at beccati dot com Reported By: matteo at beccati dot com Status: Open Bug Type: PDO related Operating System: Any PHP Version: 5.3.0beta1 New Comment:
Here's a patch: http://www.beccati.com/misc/pdo_pgsql_bug47297_php_5.3.patch Previous Comments: ------------------------------------------------------------------------ [2009-02-04 07:24:58] matteo at beccati dot com Description: ------------ The common test pdo_033.phpt fails on PgSQL because it's using a char(100) field, which will be right padded with spaces once retrieved, even though the actual output doesn't show that. Using a char field with the correct size fixes the issue, while surely remaining compatible with other database type. Reproduce code: --------------- php -n run-tests.php --show-diff ext/pdo_pgsql/tests/common.phpt Expected result: ---------------- PASS Postgres PDO Common: PDO::quote() [ext/pdo_pgsql/tests/pdo_033.phpt] Actual result: -------------- TEST 49/55 [ext/pdo/tests/pdo_033.phpt] ========DIFF======== 005+ [t] => !"#$%&'()*+,-./0123456789:;<=>?...@abcdefghijklmnopqrstuvwxyz[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ 005- [t] => !"#$%&'()*+,-./0123456789:;<=>?...@abcdefghijklmnopqrstuvwxyz[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ ========DONE======== FAIL Postgres PDO Common: PDO::quote() [ext/pdo_pgsql/tests/pdo_033.phpt] ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=47297&edit=1
