note 13629 added to function.extract.php
| From: | php-general at lists dot php dot net | Date: | Mon, 25 Jun 2001 14:27:35 +0000 |
| Subject: | note 13629 added to function.extract.php | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-14648@lists.php.net to get a copy of this message | ||
All you need to do to overwrite NULL fields from previous rows is use mysql_fetch_assoc instead of
mysql_fetch_array :
$result = mysql_query($some_query);
while($row = mysql_fetch_assoc($result)){
extract($row);
// do something useful
}
Ivan
http://www.php.net/manual/en/function.extract.php