Forum Moderators: coopster
let's say i have
------------------------------------------------
date1 ¦ date2 ¦ date3
------------------------------------------------
2006-06-01 ¦ 2006-06-15 ¦ 2006-09-19
------------------------------------------------
and my select statement returns this 3 value.
is there any way i can write in PHP to get the earliest or the latest date?
let's say:
$earliest = #*$!($row[date1], $row[date2], $row[date3]) <- returns ("2006-06-01")$latest = #*$!($row[date1], $row[date2], $row[date3]) <- returns ("2006-09-19")
i tried to get these from mysql command like if possible but cant find any way to do it..
i guess there's no function to this..
select #*$!XX(date1,date2,date3) <--returns '2006-06-01 '
select YYYYY(date1,date2,date3) <--returns '2006-09-19