Dear all,
In the table "tempnews", I want to get the latest date-time of the column "pdate" only. Please give me help on how to write the code in the php webpage, thanks
Sincerely yours, Simon
Will this help?
"select * from table order by pdate limit 5 order by desc"
order by desc will sort, limit 5 will show only 5 last post.
gah, something went fubar...
"select * from tempnews order by pdate desc limit 5"
would be better probalbly...
SELECT MAX(pdate) AS maxdate FROM your_table
what kind of database is it? I tried this one using sql plus, it doesn't work.