mirror of https://github.com/BOINC/boinc.git
Added additional index to consent table as well as foreign_key index.
This commit is contained in:
parent
60ee7e85f9
commit
c4c2ae69ba
|
@ -182,6 +182,12 @@ alter table sent_email
|
|||
alter table consent
|
||||
add index userid_ctid(userid, consent_type_id);
|
||||
add index consent_timestamp(consent_time);
|
||||
add index flag_ctid(consent_flag, consent_type_id);
|
||||
|
||||
alter table consent
|
||||
add foreign key(consent_type_id)
|
||||
references consent_type(id)
|
||||
on update cascade;
|
||||
|
||||
alter table consent_type
|
||||
add index consent_name(shortname);
|
||||
|
|
|
@ -1173,7 +1173,8 @@ function update_5_17_2018() {
|
|||
source varchar(255) not null,
|
||||
primary key (id),
|
||||
index userid_ctid(userid, consent_type_id),
|
||||
index consent_timestamp(consent_time)
|
||||
index consent_timestamp(consent_time),
|
||||
index flag_ctid(consent_flag, consent_type_id)
|
||||
) engine=InnoDB;
|
||||
");
|
||||
|
||||
|
@ -1189,6 +1190,12 @@ function update_5_17_2018() {
|
|||
) engine=InnoDB;
|
||||
");
|
||||
|
||||
do_query("alter table consent
|
||||
add foreign key(consent_type_id)
|
||||
references consent_type(id)
|
||||
on update cascade;
|
||||
");
|
||||
|
||||
do_query("insert into consent_type
|
||||
(id, shortname, description, enabled, protect, privacypref) values
|
||||
(1, 'ENROLL', 'General terms-of-use for this BOINC project.', 0, 1, 0);
|
||||
|
|
Loading…
Reference in New Issue