View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
08675 | Bug reports | Installation | public | 2014-02-06 17:07 | 2014-02-12 21:20 |
Reporter | atisne | Assigned To | c_schmitz | ||
Priority | normal | Severity | minor | ||
Status | closed | Resolution | fixed | ||
Product Version | 2.05+ | ||||
Fixed in Version | 2.05+ | ||||
Summary | 08675: Migration issue from 1.90 to 2.05 | ||||
Description | I've experienced issues during the migration of limesurvey 1.90 to 2.05 with the postgresql DB update. (It seems to be the same as CrystalBlood [https://www.limesurvey.com/en/forum/installation-a-update-issues/95371-possible-bug-on-migrating-database-to-2-05].) | ||||
Steps To Reproduce | Instructions of http://manual.limesurvey.org/Upgrading_from_a_previous_version | ||||
Additional Information | I fix the three errors as follow : 1- I deleted (and restore) primary key for the table 'labels' before alter column (because column 'language' is part of primary key).
2- I added TransactionBookmark when dropping index 'email' on table 'users' (because postgresql does not suffer failing during a transaction).
3- 1- I deleted primary key for the table 'user_in_groups' before alter column (because columns 'ugid' and 'uid' are part of primary key). Primary key are created some lines after.
It works for me, but, as I am not sure this fix is relevant in all cases, I just provide a patch and not a pull request. | ||||
Tags | No tags attached. | ||||
Attached Files | patch (1,805 bytes)
--- updatedb_helper.php.orig 2014-02-06 14:17:19.000000000 +0100 +++ updatedb_helper.php 2014-02-06 15:04:08.000000000 +0100 @@ -502,7 +502,9 @@ alterColumn('{{groups}}','group_name',"{$sVarchar}(100)",false , ''); alterColumn('{{labels}}','code',"{$sVarchar}(5)",false , ''); + dropPrimaryKey('labels'); alterColumn('{{labels}}','language',"{$sVarchar}(20)",false , 'en'); + addPrimaryKey('labels', array('lid', 'sortorder', 'language')); alterColumn('{{labelsets}}','label_name',"{$sVarchar}(100)",false , ''); alterColumn('{{questions}}','parent_qid','integer',false ,'0'); alterColumn('{{questions}}','title',"{$sVarchar}(20)",false , ''); @@ -572,11 +574,13 @@ alterColumn('{{users}}','htmleditormode',"{$sVarchar}(7)",true,'default'); alterColumn('{{users}}','dateformat','integer',false , 1); try{ + setTransactionBookmark(); $oDB->createCommand()->dropIndex('email','{{users}}'); } catch(Exception $e) { // do nothing + rollBackToTransactionBookmark(); } $oDB->createCommand()->update('{{user_groups}}',array('name'=>''),"name is NULL"); @@ -892,6 +896,7 @@ alterColumn('{{users}}','parent_id','integer',false); try { setTransactionBookmark(); alterColumn('{{surveys_languagesettings}}','surveyls_survey_id',"integer",false); } catch(Exception $e) { rollBackToTransactionBookmark(); } alterColumn('{{user_groups}}','owner_id',"integer",false); + dropPrimaryKey('user_in_groups'); alterColumn('{{user_in_groups}}','ugid',"integer",false); alterColumn('{{user_in_groups}}','uid',"integer",false); | ||||
Bug heat | 2 | ||||
Complete LimeSurvey version number (& build) | 140204 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | FireFox | ||||
Database type & version | Postgresql 8.3 | ||||
Server OS (if known) | centOS | ||||
Webserver software & version (if known) | apache 2.2.3 | ||||
PHP Version | 5.4.24 | ||||
Date Modified | Username | Field | Change |
---|---|---|---|
2014-02-06 17:07 | atisne | New Issue | |
2014-02-06 17:07 | atisne | File Added: patch | |
2014-02-07 15:08 | c_schmitz | Assigned To | => c_schmitz |
2014-02-07 15:08 | c_schmitz | Status | new => assigned |
2014-02-07 15:08 | c_schmitz | Status | assigned => resolved |
2014-02-07 15:08 | c_schmitz | Fixed in Version | => 2.05+ |
2014-02-07 15:08 | c_schmitz | Resolution | open => fixed |
2014-02-07 15:08 | c_schmitz | Note Added: 28552 | |
2014-02-07 15:09 | c_schmitz | Changeset attached | => LimeSurvey master fc74fd2c |
2014-02-07 15:09 | c_schmitz | Note Added: 28553 | |
2014-02-12 21:20 | c_schmitz | Note Added: 28684 | |
2014-02-12 21:20 | c_schmitz | Status | resolved => closed |