This is the table structure -
Table: test +------+---------+ | PAGE | CONTENT | +------+---------+ | 1 | ABC | +------+---------+ | 2 | DEF | +------+---------+ | 3 | GHI | +------+---------+
PAGE is Primary with an INT(11) data type. It is not auto increment. CONTENT refers to the TEXT data type.
In PHP, I do -
$result = mysql_query(SELECT MAX(PAGE) FROM test); $row = mysql_fetch_array($result); echo $row["PAGE"];
There is no conclusion. At all. If I do something like echo "Value : ".$row["PAGE"]; , all I see is Value :
The SELECT * FROM test query works just fine. Am I mistaken somewhere using the MAX() syntax?
I want it not to return the maximum PAGE value yet.
source share