View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
17608Bug reportsDatabase designpublic2021-09-24 12:18
Reporterbbraeuer Assigned Toollehar  
PrioritynoneSeveritycrash 
Status resolvedResolutionfixed 
Product Version4.5.x 
Summary17608: Database Update ist not working
DescriptionDatabase upgrade 473 to 475 is not working

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'limesurvey.lime_labels' doesn't exist
Steps To Reproduceuse today's Comfort Update
Additional InformationEin Fehler trat während des Datenbankupdates auf. Fehlerinformation:
CDbCommand konnte das SQL-Statement nicht ausführen: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'limesurvey.lime_labels' doesn't exist


Datei updatedb_helper.php, Zeile 4951.
TagsNo tags attached.
Bug heat6
Complete LimeSurvey version number (& build)current from comfort update
I will donate to the project if issue is resolvedNo
Browser
Database type & versionuptodate
Server OS (if known)
Webserver software & version (if known)
PHP Versionuptodate

Users monitoring this issue

User List There are no users monitoring this issue.

Activities

ollehar

ollehar

2021-09-20 15:45

administrator   ~66535

Thank you for reporting this, I will release a fix very soon.
ollehar

ollehar

2021-09-20 16:13

administrator   ~66540

Last edited: 2021-09-22 16:09

View 2 revisions

Fix has been released, please update and try again.
bbraeuer

bbraeuer

2021-09-20 16:15

reporter   ~66541

Last edited: 2021-09-22 16:09

Thanks, but how can I update now? Going to the admin page leads only to the database upgrade page :/
ollehar

ollehar

2021-09-20 16:26

administrator   ~66542

Last edited: 2021-09-22 16:09

You might have to apply the fixing patch manually. You can see the changes here: https://github.com/LimeSurvey/LimeSurvey/commit/6a4cdee9289d82a8baf8e9905e9af27b21d90d66

This is new new version of updatedb_helper.php: https://raw.githubusercontent.com/LimeSurvey/LimeSurvey/6a4cdee9289d82a8baf8e9905e9af27b21d90d66/application/helpers/update/updatedb_helper.php
bbraeuer

bbraeuer

2021-09-20 16:32

reporter   ~66543

Last edited: 2021-09-22 16:09

Thanks, it's working now :-)
ollehar

ollehar

2021-09-20 16:33

administrator   ~66544

Last edited: 2021-09-22 16:09

Great!
exnovo

exnovo

2021-09-21 08:28

reporter   ~66548

Last edited: 2021-09-22 16:09

Hi!

Another issue with the same update (473->475) is identified (two different installations)

An non-recoverable error happened during the update. Error details:
CDbCommand failed to execute the SQL statement: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'language' in 'where clause'


File updatedb_helper.php, line 8072.
ollehar

ollehar

2021-09-21 09:41

administrator   ~66552

Last edited: 2021-09-22 16:09

Hm, ok, will check.
ollehar

ollehar

2021-09-21 10:03

administrator   ~66568

Last edited: 2021-09-22 16:09

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=32734
ollehar

ollehar

2021-09-21 10:56

administrator   ~66569

Last edited: 2021-09-22 16:09

Please try the latest patch release. Let us know if the problem remains. Thank you!
exnovo

exnovo

2021-09-21 15:23

reporter   ~66573

Last edited: 2021-09-22 16:09

No, there is issue now with the execution of SQL statement for creating a new index - see below:

An non-recoverable error happened during the update. Error details:
CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '33-AO01' for key 'lime_idx5_labels'


File updatedb_helper.php, line 4955.
ollehar

ollehar

2021-09-21 16:27

administrator   ~66574

Last edited: 2021-09-22 16:09

@exnovo OK, can you maybe upload your database dump here? Mark the comment as private.
ollehar

ollehar

2021-09-21 16:50

administrator   ~66575

Last edited: 2021-09-22 16:09

The problem is duplicated label set codes in a single label set.
ollehar

ollehar

2021-09-22 16:03

administrator   ~66590

Last edited: 2021-09-22 16:09

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=32743
ollehar

ollehar

2021-09-22 16:06

administrator   ~66591

Last edited: 2021-09-22 16:09

@exnovo Can you apply this commit manually and try again? https://github.com/LimeSurvey/LimeSurvey/commit/022518db2288b5dcc33cefba7eaea3f4ee1d6d2f

Your database had orphan labels - labels with lid = 0, without a belonging label set. I've added code to remove such orphans.
exnovo

exnovo

2021-09-22 17:06

reporter   ~66592

Thank you - this works.
The other database file still encountered an issue, but it was also related to some orphan records - which were found during consistency check and fixed manually.

Related Changesets

LimeSurvey: master f8a0a94c

2021-09-21 10:03:18

ollehar

Details Diff
Fixed issue 17608: Label sets have no language column in latest dbversion Affected Issues
17608
mod - application/helpers/update/updatedb_helper.php Diff File

LimeSurvey: master 022518db

2021-09-22 16:03:40

ollehar

Details Diff
Fixed issue 17608: Remove orphan labels before adding table unique constraint Affected Issues
17608
mod - application/helpers/update/updatedb_helper.php Diff File

Issue History

Date Modified Username Field Change
2021-09-20 15:42 bbraeuer New Issue
2021-09-20 15:45 ollehar Note Added: 66535
2021-09-20 15:45 ollehar Bug heat 0 => 2
2021-09-20 16:13 ollehar Assigned To => ollehar
2021-09-20 16:13 ollehar Status new => resolved
2021-09-20 16:13 ollehar Resolution open => fixed
2021-09-20 16:13 ollehar Note Added: 66540
2021-09-20 16:14 ollehar Note Edited: 66540 View Revisions
2021-09-20 16:15 bbraeuer Note Added: 66541
2021-09-20 16:15 bbraeuer Bug heat 2 => 4
2021-09-20 16:26 ollehar Note Added: 66542
2021-09-20 16:32 bbraeuer Note Added: 66543
2021-09-20 16:33 ollehar Note Added: 66544
2021-09-21 08:28 exnovo Note Added: 66548
2021-09-21 08:28 exnovo Bug heat 4 => 6
2021-09-21 09:41 ollehar Note Added: 66552
2021-09-21 09:45 c_schmitz Bug heat 6 => 8
2021-09-21 09:45 c_schmitz Status resolved => closed
2021-09-21 09:50 c_schmitz Status closed => feedback
2021-09-21 09:50 c_schmitz Resolution fixed => reopened
2021-09-21 09:54 c_schmitz Bug heat 8 => 6
2021-09-21 10:03 ollehar Changeset attached => LimeSurvey master f8a0a94c
2021-09-21 10:03 ollehar Note Added: 66568
2021-09-21 10:03 ollehar Resolution reopened => fixed
2021-09-21 10:05 ollehar Status feedback => testing
2021-09-21 10:56 ollehar Note Added: 66569
2021-09-21 15:23 exnovo Note Added: 66573
2021-09-21 16:27 ollehar Note Added: 66574
2021-09-21 16:50 ollehar Note Added: 66575
2021-09-22 16:03 ollehar Changeset attached => LimeSurvey master 022518db
2021-09-22 16:03 ollehar Note Added: 66590
2021-09-22 16:06 ollehar Note Added: 66591
2021-09-22 17:06 exnovo Note Added: 66592
2021-09-24 12:18 ollehar Status testing => resolved