try this (it's untested) --
Code:
select a.albumid
, a.title
, FROM_UNIXTIME(MAX(p.time),'%M %e, %Y %r'))
as lastdatetime
from albums a
inner
join photos p
on a.albumid = p.albumid
group by a.albumid
, a.title
order by a.albumid desc
if you convert a unix timestamp column to a string format where the month comes first, and then take the max of that string, then Sep comes after Oct, Nov comes after Dec, Jan comes after Feb, etc.
what you want to do is take the max unix timestamp and then format that
rudy
Bookmarks