Right, I am developing a ticket system. I have two tables:
mos_wats_ticket
watsid int(11)
ticketid int(11)
ticketname varchar(25)
vis tinyint(1)
open tinyint(1)
datetime timestamp(14)
mos_wats_msg
msgid int(11)
ticketid int(11)
watsid int(11)
msg text
datetime timestamp(14)
And I display all tickets bt executing an SQL query that selects tickets in order of datetime - note this is the submited datetime. What i would like it to display a list of tickets ordered by the last message datetime - much as threads are ordered in this forum.
Can I use SQL to do this or will I need to script this?








Bookmarks