Huji schreef:
On Feb 7, 2008 3:16 AM, Simetrical Simetrical+wikilist@gmail.com wrote:
You know, exactly why do we have a separate recentchanges table at all?
The thing is, recentchanges boosts things a lot. For example, if I edit a page and change its size from 2KB to 4KB, then you edit it to 6KB, and then an admin deletes the middle version, the wiki will be able to show them in a matter of milliseconds, because every step (and every size) is stored in recentchanges table. However, if the wiki was supposed to generate the recentchanges using revision and logs table, it had to get the rev_id of the 6KB edition and then find the previous revision (which means it should have search both "revision" and "archive" tables for it, because the previous revision could be deleted, which is a more complicated task, with more load on the database backend. Also, it had to mix the logs and edit events, and then sort all of them using their timestamp, which is again a pain in ass.
Note that: 1. Deleted revisions and revisions of deleted pages don't show up in RC 2. The elaborate query you're talking about wouldn't be necessary, as we'd be adding rev_old_len and rev_new_len and all kinds of other fancy flags the recentchanges table currently has
Roan Kattouw (Catrope)