From:             galactic dot void at googlemail dot com
Operating system: 
PHP version:      5.3CVS-2008-04-11 (snap)
PHP Bug Type:     PDO related
Bug description:  PDO::FETCH_FUNC and namespaces

Description:
------------
PDO::FETCH_FUNC does not work with functions and classes that are inside a
namespace.

Reproduce code:
---------------
namespace Foo;

function bar() { var_dump(func_get_args()); }

$pdo  = new ::PDO();
$stmt = $pdo->query('SELECT * FROM foo_bar');
$stmt->fetchAll(PDO::FETCH_FUNC, 'Foo::bar');

Expected result:
----------------
array(2) {
  [0]=>
  string(4) "test"
  [1]=>
  string(4) "data"
}


Actual result:
--------------
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error:
user-supplied class does not exist in /home/operations/Desktop/PHP.php on
line 8


-- 
Edit bug report at http://bugs.php.net/?id=44702&edit=1
-- 
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=44702&r=trysnapshot52
Try a CVS snapshot (PHP 5.3): 
http://bugs.php.net/fix.php?id=44702&r=trysnapshot53
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=44702&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=44702&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=44702&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=44702&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=44702&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=44702&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=44702&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=44702&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=44702&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=44702&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=44702&r=globals
PHP 4 support discontinued:   http://bugs.php.net/fix.php?id=44702&r=php4
Daylight Savings:             http://bugs.php.net/fix.php?id=44702&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=44702&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=44702&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=44702&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=44702&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=44702&r=mysqlcfg

Reply via email to