Don't understand so well.
You can try this
<?php
$sql = "SELECT a, b, c FROM 123";
$rs = $db->query($sql);
while($row = $rs->fetchRow()){
$arr = array($row[0], $row[1], $row[2]);
while(list($key, $val) = each($arr)){
print($val."<br/>\n");
}
}
?>
or this
<?php
$sql = "SELECT a, b, c FROM 123";
$arr = array(0,1,2);
$rs = $db->query($sql);
while($row = $rs->fetchRow()){
while(list($key, $val) = each($arr)){
print($row[$val]."<br/>\n");
}
}
?>
The two piece of code works differently. I can't undertstand exactly what you want.
Else you must post more information.
See you.