From: arjen Date: Tue, 5 Aug 2003 07:43:02 +0000 (+0000) Subject: Added index to the history table. X-Git-Tag: V0_0_7~15 X-Git-Url: http://www.andromeda.nl/gitweb/?p=gnucomo.git;a=commitdiff_plain;h=e9fa065dcae32230ceffadcf498cbfdeb323aeb7 Added index to the history table. --- diff --git a/src/database/create.sql b/src/database/create.sql index 362fd86..1c3ba8d 100644 --- a/src/database/create.sql +++ b/src/database/create.sql @@ -12,7 +12,10 @@ -- DBA create the database and give access permissions. -- -- $Log: create.sql,v $ --- Revision 1.14 2003-07-09 07:14:59 arjen +-- Revision 1.15 2003-08-05 07:43:24 arjen +-- Added index to the history table. +-- +-- Revision 1.14 2003/07/09 07:14:59 arjen -- New database tables: notification_check, notification_check_buffer, -- notification_check_line and object_statistics. -- @@ -160,6 +163,8 @@ CREATE TABLE "history" ); +CREATE INDEX history_pid_mod ON history(paramid, modified); + -- -- diff --git a/src/gcm_daemon/classes/gnucomo_db_version.php b/src/gcm_daemon/classes/gnucomo_db_version.php index ff05e7e..caea052 100644 --- a/src/gcm_daemon/classes/gnucomo_db_version.php +++ b/src/gcm_daemon/classes/gnucomo_db_version.php @@ -425,6 +425,10 @@ case 40: $local_sql = "CREATE INDEX obj_stat_objid ON object_statistics USING btree (objectid)"; $dbms->query($local_sql); +case 41: + $local_sql = "CREATE INDEX history_pid_mod ON history(paramid, modified)"; + $dbms->query($local_sql); + //These columns have to be removed when a new version of PGSQL has become mainstream that supportsa DROP COLUMN /*