Some improvements in efficiency of Recent Activity.

There is now a new field in forum_discussions which has the userid
of the author in it.  This saves a lookup every time to forum_posts.

There is also some caching and rearrangement of the logic.

It seems to work OK, I'm about to do some speed tests on moodle.org
This commit is contained in:
moodler 2004-01-14 11:50:29 +00:00
parent da8079852c
commit d05956ac9f
8 changed files with 80 additions and 19 deletions

View file

@ -32,6 +32,7 @@ CREATE TABLE prefix_forum_discussions (
forum int(10) unsigned NOT NULL default '0',
name varchar(255) NOT NULL default '',
firstpost int(10) unsigned NOT NULL default '0',
userid int(10) unsigned NOT NULL default '0',
assessed tinyint(1) NOT NULL default '1',
timemodified int(10) unsigned NOT NULL default '0',
PRIMARY KEY (id)