From e6ea5c066419f997597583c2ba060a2b5cd0103e Mon Sep 17 00:00:00 2001 From: moodler Date: Wed, 20 Aug 2003 12:09:15 +0000 Subject: [PATCH] Fixed some bad Postgres SQL that I made! :-) --- backup/db/postgres7.sql | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/backup/db/postgres7.sql b/backup/db/postgres7.sql index 8a951ee1f1..b104f6846d 100644 --- a/backup/db/postgres7.sql +++ b/backup/db/postgres7.sql @@ -6,16 +6,17 @@ # CREATE TABLE prefix_backup_files ( - prefix_backup_codetypepath_idx PRIMARY KEY, backup_code integer NOT NULL default '0', file_type varchar(10) NOT NULL default '', path varchar(255) NOT NULL default '', old_id integer default NULL, new_id integer default NULL, -) TYPE=MyISAM COMMENT='To store and recode ids to user and course files.'; + PRIMARY KEY (backup_code, file_type, path) +); + # -------------------------------------------------------- -CREATE INDEX prefix_backup_codetypepath_idx ON prefix_backup_files (backup_code,file_type,path) +CREATE INDEX prefix_backup_codetypepath_idx ON prefix_backup_files (backup_code,file_type,path); # # Table structure for table prefix_backup_ids @@ -28,7 +29,9 @@ CREATE TABLE prefix_backup_ids ( old_id int(10) unsigned NOT NULL default '0', new_id int(10) unsigned default NULL, info mediumtext, -) TYPE=MyISAM COMMENT='To store and convert ids in backup/restore'; + PRIMARY KEY (backup_code, table_name, old_id) +); + +CREATE INDEX prefix_backup_codenameid_idx ON prefix_backup_ids (backup_code,table_name,old_id); -CREATE INDEX prefix_backup_codenameid_idx ON prefix_backup_ids (backup_code,table_name,old_id) -- 2.39.5