4
Catz,
Good idea. I've only seen 2-3 cases of this, but maybe that is already common enough to warrant doing something about it. As far as I can tell, there is nothing inherently 'wrong' with how XOOPS interacts with the database to be causing this. I suspect certain versions of PHP/mysql on certain platforms have bugs which allow tables to become corrupted when things are not shut down correctly or when multiple users post simultaneously. This is just a guess. Personally I have had this problem not with XOOPS but with another script (phpwiki running under linux, MySQL 3.23, php 4.1.2), where a table suddenly is corrupted for no obvious reason.
We could add an admin link to 'check' and 'repair' the tables (probably ALL XOOPS tables, not just forums). But I've observed that 'repair table' can sometimes lose a significant amount of data (mysql command-line will tell you this ahead of time). In these situations you really need to go through *all* the e.g. forums tables and make sure everything is properly cross-referenced and delete data for partially lost records (e.g. if you have the post title but the 'text' is gone). I'm not sure an admin 'button' can be written sufficiently well that it does the right thing in the general case.
Anyone else who has had this issue, could you post a brief summary of the problem and your fix, and whether you lost any database records or experienced other symptoms after the fix? Anyone have any ideas *why* this sometimes happens?
Thanks!