diff options
author | Dave Lawrence <dlawrence@mozilla.com> | 2012-07-23 17:45:38 -0400 |
---|---|---|
committer | Dave Lawrence <dlawrence@mozilla.com> | 2012-07-23 17:45:38 -0400 |
commit | bfabb024d429c1ec92a48ab01e528838ab289a56 (patch) | |
tree | cba784186a6d385e310d810c2678203b700e1033 | |
parent | 3dce1aa3a9ec8898b0dbcadfc3d7a4bdb5893327 (diff) | |
download | bugs-bfabb024d429c1ec92a48ab01e528838ab289a56.tar bugs-bfabb024d429c1ec92a48ab01e528838ab289a56.tar.gz bugs-bfabb024d429c1ec92a48ab01e528838ab289a56.tar.bz2 bugs-bfabb024d429c1ec92a48ab01e528838ab289a56.tar.xz bugs-bfabb024d429c1ec92a48ab01e528838ab289a56.zip |
Bug 764466 - Add a primary key to the profiles_activity table
r=glob, a=LpSolit
-rw-r--r-- | Bugzilla/DB/Schema.pm | 2 | ||||
-rw-r--r-- | Bugzilla/Install/DB.pm | 4 | ||||
-rwxr-xr-x | contrib/recode.pl | 1 |
3 files changed, 7 insertions, 0 deletions
diff --git a/Bugzilla/DB/Schema.pm b/Bugzilla/DB/Schema.pm index 7293d25d8..1ca7d9d7c 100644 --- a/Bugzilla/DB/Schema.pm +++ b/Bugzilla/DB/Schema.pm @@ -903,6 +903,8 @@ use constant ABSTRACT_SCHEMA => { profiles_activity => { FIELDS => [ + id => {TYPE => 'MEDIUMSERIAL', NOTNULL => 1, + PRIMARYKEY => 1}, userid => {TYPE => 'INT3', NOTNULL => 1, REFERENCES => {TABLE => 'profiles', COLUMN => 'userid', diff --git a/Bugzilla/Install/DB.pm b/Bugzilla/Install/DB.pm index f516748b9..194ed310b 100644 --- a/Bugzilla/Install/DB.pm +++ b/Bugzilla/Install/DB.pm @@ -682,6 +682,10 @@ sub update_table_definitions { $dbh->bz_add_column('bugs_activity', 'id', {TYPE => 'MEDIUMSERIAL', NOTNULL => 1, PRIMARYKEY => 1}); + # 2012-06-13 dkl@mozilla.com - Bug 764466 + $dbh->bz_add_column('profiles_activity', 'id', + {TYPE => 'MEDIUMSERIAL', NOTNULL => 1, PRIMARYKEY => 1}); + ################################################################ # New --TABLE-- changes should go *** A B O V E *** this point # ################################################################ diff --git a/contrib/recode.pl b/contrib/recode.pl index cf0997a52..de204f155 100755 --- a/contrib/recode.pl +++ b/contrib/recode.pl @@ -32,6 +32,7 @@ use constant SPECIAL_KEYS => { # bugs_activity since 4.4 has a unique primary key added bugs_activity => 'bug_id,bug_when,fieldid', profile_setting => 'user_id,setting_name', + # profiles_activity since 4.4 has a unique primary key added profiles_activity => 'userid,profiles_when,fieldid', setting_value => 'name,value', # longdescs didn't used to have a PK, before 2.20. |