luckybird
05-03-2006, 05:05 PM
In my BBS, I have two tables: thread and message.
Each has a field "time" which is a Timestamp type updated when the record is updated.
If I want to list the threads, I do it in the descending order of it's table's time.
However, when a message of that thread is updated or created, the corresponding thread's time should also be updated so that the most recent thread(the thread with the latest message) should be displayed first.
But how can I order the time of the thread according to the time of the message?
Could anybody give me some advice?
Thank you!
Each has a field "time" which is a Timestamp type updated when the record is updated.
If I want to list the threads, I do it in the descending order of it's table's time.
However, when a message of that thread is updated or created, the corresponding thread's time should also be updated so that the most recent thread(the thread with the latest message) should be displayed first.
But how can I order the time of the thread according to the time of the message?
Could anybody give me some advice?
Thank you!