On Mar 28, 2005 12:08 PM, Brion Vibber brion@pobox.com wrote:
revision and text now use separate row ID numbers in HEAD. A revision row refers to text.old_id with its rev_text_id key; this allows text revisions to be stored independently of a given revision.
It occurred to me when I saw this that this means that displaying the current content of a page requires reading data from all three tables: page_current refers to a rev_id, and rev_text_id then refers to the 'old_id' in the text table. This seems inefficient somehow, since I wouldn't expect anything from the revision table is actually needed during normal page viewing (it being entirely history metadata). Moreover, it looks to me like displaying the page's history doesn't refer to page_latest at all, so would it be possible and appropriate to make page_latest point directly to the 'text', rather than the 'revision'?
If I've missed some obvious reason why this is poppycock, I apologise for wasting your time. :)