Hi abhijit,
If you want to find the second highest value from a table, then simply order by the field you are interested in and take the second row, like this:
<?php
$query = mysql_query("SELECT number FROM table ORDER BY number DESC LIMIT 2");
$second_highest = mysql_result($query,1,0);
echo "the answer to your question is $second_highest";
?>
Nov 27, 2009