View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
17097 | Bug reports | Installation | public | 2021-02-15 22:08 | 2021-03-22 09:12 |
Reporter | Pit | Assigned To | c_schmitz | ||
Priority | none | Severity | minor | ||
Status | closed | Resolution | unable to reproduce | ||
Product Version | 4.4.4 | ||||
Summary | 17097: function cleanLanguagesFromSurvey in module common_helper.php | ||||
Description | Since the change from v3 to v4 the function mentioned above uses LEFT JOIN
All tables have field language and $sqllang contains field language which is now ambiguous. v3 did not use the LEFT JOIN so it was not a problem. Now ajax-function in save global settings returns error because of the sql error. Proposal: use qualified field language. Furthermore in sql installation field language is missing in table answers and questions, Shoud be there. | ||||
Tags | No tags attached. | ||||
Bug heat | 6 | ||||
Complete LimeSurvey version number (& build) | 4.0 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | |||||
Database type & version | mysql 5.1 | ||||
Server OS (if known) | |||||
Webserver software & version (if known) | |||||
PHP Version | 7.4.15 | ||||
Can you explain the exact way to reproduce an issue please ?
No : it's false answers and questions must not have a language field : |
|
Isn't it obvious? The sql query menitoned above causes an mysql error. Start e.g. phpmyadmin and enter with "lime_" as table prefix and an existing SurveyID assuming "en" as language SELECT ls.id from lime_answer_l10ns ls JOIN lime_answers a on ls.aid=a.aid JOIN lime_questions q on a.qid=q.qid WHERE sid={$iSurveyID} AND language='en' mysql throws an error "language is ambiguous" You can trace the error in menu "General survey settings". Save settings and see the error 500 appearing on browser console. PS.: In my report above "LEFT JOIN" should be replaced with "JOIN" |
|
The tables answers and questions don't have a language field anymore. |
|
I have tested before posting the bug report: Field language removed in answers: Ok The reason: Perhaps I am wrong but I have done a safe update from v3 to v4 and fields language are still present. To be in a safe harbour: Use qualfied field like ls.language in common_helper.php. |
|
maybe you have plugins ? It was removed from DB when update to version 400. Maybe you use a 4.0.0 release candidate ?
We can remove it :) |
|
getAnswerQuery is deprecated and thus not updated. Just removing the fields will not help, as the data is converted by the upgrade functions to the answers_i18n table. |
|
Closing because we cannot reproduce. |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2021-02-15 22:08 | Pit | New Issue | |
2021-02-16 11:58 | DenisChenu | Note Added: 62277 | |
2021-02-16 13:07 | Pit | Note Added: 62284 | |
2021-02-16 17:55 | c_schmitz | Assigned To | => c_schmitz |
2021-02-16 17:55 | c_schmitz | Status | new => feedback |
2021-02-16 17:55 | c_schmitz | Note Added: 62297 | |
2021-02-16 18:09 | c_schmitz | Note Edited: 62297 | |
2021-02-16 19:14 | Pit | Note Added: 62302 | |
2021-02-16 19:14 | Pit | Status | feedback => assigned |
2021-02-16 19:19 | DenisChenu | Note Added: 62303 | |
2021-02-16 19:21 | c_schmitz | Note Added: 62304 | |
2021-02-16 19:23 | c_schmitz | Note Edited: 62304 | |
2021-02-17 16:01 | c_schmitz | Status | assigned => feedback |
2021-03-22 09:12 | c_schmitz | Status | feedback => closed |
2021-03-22 09:12 | c_schmitz | Resolution | open => unable to reproduce |
2021-03-22 09:12 | c_schmitz | Note Added: 63514 |