Re: how to extract fields from associative array into different variables

From: Date: Tue, 16 Jun 2009 07:16:40 +0000
Subject: Re: how to extract fields from associative array into different variables
References: 1 2 3 4 5 6  Groups: php.general 
Request: Send a blank email to php-general+get-294063@lists.php.net to get a copy of this message
you dont have an alternative. you will have to loop because mysql_fetch_* functions fetch only one row at a time. you can use variable variables to achieve the above result (you will not require this if u use list() or extract() functions) http://us.php.net/manual/en/language.variables.variable.php and if you cant do the job with arrays, and u need separate variables list would be an useful function as suggested earlier. you may also consider using http://in.php.net/manual/en/function.extract.php

« previous php.general (#294063) next »