FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum Development » FUDforum 3.0+ » All forum show no thread , but message are there - 2.6
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: All forum show no thread , but message are there - 2.6 [message #30699 is a reply to message #30673] Thu, 09 March 2006 16:27 Go to previous message
idofud is currently offline  idofud   France
Messages: 7
Registered: March 2006
Karma:
Junior Member
i've tried that before with no luck

in fact i don't know how that ever happended but all page where at 3 in fud_thread_view,

i tracked down all queries, and finally i found that :
DELETE FROM phpgw_fud_thread_view WHERE forum_id=2
		     17 Query       INSERT INTO phpgw_fud_thread_view (thread_id,forum_id,page,tmp) SELECT phpgw_fud_thread.id, phpgw_fud_thread.forum_id, 2147483645, CASE WHEN thread_opt>=2 AND (phpgw_fud_msg.post_stamp+phpgw_fud_thread.orderexpiry>1141905447 OR phpgw_fud_thread.orderexpiry=0) THEN 4294967294 ELSE phpgw_fud_thread.last_post_date END AS sort_order_fld  FROM phpgw_fud_thread INNER JOIN phpgw_fud_msg ON phpgw_fud_thread.root_msg_id=phpgw_fud_msg.id WHERE forum_id=2 AND phpgw_fud_msg.apr=1 ORDER BY sort_order_fld DESC, phpgw_fud_thread.last_post_id DESC
		     17 Query       UPDATE phpgw_fud_thread_view SET page=CEILING(pos/40), pos=pos-(CEILING(pos/40)-1)*40 WHERE forum_id=2
		     17 Query       UPDATE phpgw_fud_forum SET post_count=post_count+1, thread_count=thread_count+1, last_post_id=31 WHERE id=2


when i update fud_thread_view set page=1 where forum_id=2
all was working again,
but then inserting a new post or deleting one would cause page go back to 3

i try to run the select part of the inser to see how page was calculated, (i must say it is still obscure for me! Wink )
and then it came out that the insert into failed because there was a duplicate key 2-2-xxxxxxxxxx on thread_view

i just drop the table, re create it from a sql script
run the checker and all went good!

thanks it is fixed now.

[Updated on: Thu, 09 March 2006 16:28]

Report message to a moderator

[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: all PMs lost
Next Topic: LOCK TABLES
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Wed Nov 27 17:47:28 GMT 2024

Total time taken to generate the page: 0.03733 seconds