how do i display this columns side by side
<p>im having some problem here. basically, i want to compare columns. so i fetched object and the comparing results appeared just as expected. however, it does not return the compare value anymore after i added the fetch_array to view the current table hoping that the compare value would appear beside the compare value. is there any way i could run the compare code and make it appear the table? i tried a query but it would only work in MySQL and not PHP.</p>

<pre><code>$query = "SELECT * FROM system_audit"; $result = mysql_query($query) or die(mysql_error());

echo " ID Type Setting Value ";

while($row = mysql_fetch_array($result)) { 

   echo  $row['ID']; 
   echo  $row['Type']; 
   echo  $row['Setting']; 
   echo  $row['Value'];       
}  

while ($row = mysql_fetch_object($result)) { 
    if($row-&gt;Setting != $row-&gt;Value) { 

        echo "X";
    } else { 
        echo "O"; 

    } 
}
</code></pre>
