MDB2: return by reference problems
| From: | Bram Kuijper | Date: | Mon, 26 Feb 2007 22:54:25 +0000 |
| Subject: | MDB2: return by reference problems | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-26681@lists.php.net to get a copy of this message | ||
Hi all,
I am using MDB2 as a database layer to connect to my MySQL database on a PHP 4.4.4 machine. I have some problems with the return values from MDB2's member functions query() or exec().
If I do a standard select query, like:
$qry = "SELECT * FROM mytable";
$result =& $mdb2->query($qry);
I get the following PHP error notice:
Notice: Only variables should be assigned by reference in /home/njntest4/include/libs/public/forumfuncties.inc.php
Since the examples of the query() and exec() code in the MDB2 manual always uses a return by reference, I wonder why PHP throws this notice.
Any help is appreciated.
Bram