Here's how you can do it:
$result = mysql_query(/* Your query */); while($row = mysql_fetch_assoc($result)){ // do whatever here... } // set the pointer back to the beginning mysql_data_seek($result, 0); while($row = mysql_fetch_assoc($result)){ // do whatever here... }
However, I must say that this does not seem to be the right way to handle this. Why not do the processing in the first loop?
Shef Jun 22 '11 at 11:45 2011-06-22 11:45
source share