mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
indexes for postgres
This commit is contained in:
parent
f5e82bc7f4
commit
e209e0b09e
2 changed files with 10 additions and 0 deletions
|
@ -121,6 +121,12 @@ function main_upgrade($oldversion=0) {
|
|||
}
|
||||
}
|
||||
|
||||
if ($oldversion < 2003042700) {
|
||||
/// Changing to multiple indexes
|
||||
execute_sql(" CREATE INDEX coursemoduleaction ON {$CFG->prefix}log (course,module,action) ");
|
||||
execute_sql(" CREATE INDEX courseuserid ON {$CFG->prefix}log (course,userid) ");
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
?>
|
||||
|
|
|
@ -64,6 +64,10 @@ CREATE TABLE prefix_log (
|
|||
info varchar(255) NOT NULL default ''
|
||||
);
|
||||
|
||||
CREATE INDEX coursemoduleaction ON prefix_log (course,module,action);
|
||||
|
||||
CREATE INDEX courseuserid ON prefix_log (course,userid);
|
||||
|
||||
CREATE TABLE prefix_log_display (
|
||||
module varchar(20) NOT NULL default '',
|
||||
action varchar(20) NOT NULL default '',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue