From: Brian A. <br...@ta...> - 2001-04-06 16:36:55
|
shane wrote: > >Why does "newstories" even exist? > I think it's to speed up the sql. If you've 2000 stories in the > 'stories' table, and you've got the 10 latest stories in the > 'newstories' table, then the db (for the majoriy of the hits > to the system) only has to waid through those few in the > newstories table, rather then polling the huge stories table. That is exactly why it exists. We have a better solution for 2.2 though for this. There will be three tables where there was one. There will be a meta table holding all non blob information for the site and a blob table with the sid referenced to a blob. Finally there will be a heap table that is a copy of the meta table. Selects will be made against table. This is incredibly fast and uses very little memory. Neat aye? -Brian -- _______________________________________________________ Brian Aker, br...@ta... Slashdot Senior Developer Seattle, Washington http://tangent.org/~brian/ http://slashdot.org/ _______________________________________________________ You can't grep a dead tree. |