View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
20175 | Bug reports | Print View | public | 2025-07-15 23:15 | 2025-07-15 23:15 |
Reporter | Mauro | Assigned To | |||
Priority | none | Severity | crash | ||
Status | new | Resolution | open | ||
Product Version | 6.6.x | ||||
Summary | 20175: Print survey fails on SQL Server due to duplicated ORDER BY (sortorder,code) | ||||
Description | Description The problem is due to a duplicated ORDER BY clause in the SQL query executed by the controller PrintableSurvey.php (around line 1270). The query explicitly sets order => 'sortorder,code', even though this same clause is already included in the model's defaultScope(). Temporary fix | ||||
Steps To Reproduce | Steps to reproduce Create a survey with at least one multiple-choice or array question (with answer options). Go to the survey administration menu and click "Print survey". The application tries to render the survey content and fails. Expected result Actual result CDbCommand failed to execute the SQL statement: SQLSTATE[42000]: ORDER BY sortorder, code, sortorder, code Workaround tested: | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
Bug heat | 0 | ||||
Complete LimeSurvey version number (& build) | 6.15.4+250710 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | |||||
Database type & version | Microsoft SQL Server 2019, ODBC Driver 17 | ||||
Server OS (if known) | Ubuntu 22.04 | ||||
Webserver software & version (if known) | |||||
PHP Version | 8.3.19 | ||||