That is what I was thinking. But it might be easier if you make an orderid field and default it to 0, and leave it as is for normal threads. Then when merging threads, find the highest value of that field and increase it by one, and set the posts for the thread you want to come second to that new value (i.e 1 if it is the first time you're merging. Or maybe have a text field that you can fill in when merging so you can control the order of posts).
Then when showing a thread order by orderid then dateline (or whatever field it already uses).
Edit: Another thought, maybe you could avoid adding a column to the post table (which might be good if you already have a large number of post) by making a new table with just postid and orderid (and maybe an index on postid), then join that table in the showthread query. (But I'm not a db expert or anything).
|