View Issue Details

This issue affects 1 person(s).
 8
IDProjectCategoryView StatusLast Update
19104Bug reportsDatabase designpublic2026-10-31 19:54
Reportermferraz Assigned Toc_schmitz  
PrioritynoneSeveritycrash 
Status resolvedResolutionfixed 
Product Version6.2.x 
Summary19104: SQLSTATE[54011]: Too many columns: 7 ERROR: target lists can have at most 1664 entries
Description

Hi.

While exporting the survey answers from a survey, we got the following error:
SQLSTATE[54011]: Too many columns: 7 ERROR: target lists can have at most 1664 entries

Steps To Reproduce

Steps to reproduce

Exporting the answers

Expected result

(Write here what you expected to happen)

Actual result

(Write here what happened instead)

TagsNo tags attached.
Attached Files
limesurvey_survey_988487.lss (1,572,903 bytes)
Bug heat8
Complete LimeSurvey version number (& build)6.2.8+230921
I will donate to the project if issue is resolvedYes
Browser
Database type & versionPostgreSQL 13+225
Server OS (if known)
Webserver software & version (if known)
PHP Version8.1
Git branch / Pull Request URL

Users monitoring this issue

mferraz

Activities

mferraz

mferraz

2023-09-26 10:25

reporter   ~77323

Still getting the same with the last update:
6.2.9+230925

gabrieljenik

gabrieljenik

2023-10-17 15:04

developer   ~77740

Can you please set debug to 2, re run and capture the error stack on a pdf?

c_schmitz

c_schmitz

2026-10-31 18:56

administrator   ~87046

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

c_schmitz

c_schmitz

2026-10-31 19:54

administrator   ~87053

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

Related Changesets

LimeSurvey: master ec070327

2026-10-31 18:55

c_schmitz


Details Diff
Fixed issue 19104: Exporting responses of a survey with many questions failed on PostgreSQL with a "Too many columns" error
Dev Participant and timing values are now loaded with separate queries for each page of responses instead of being joined into the response query
Affected Issues
19104
mod - application/helpers/admin/export/SurveyDao.php Diff File
mod - application/helpers/admin/export/Writer.php Diff File
mod - application/helpers/admin/exportresults_helper.php Diff File
add - tests/unit/helpers/admin/export/ExportJoinedColumnsTest.php Diff File

LimeSurvey: master 2b58cdfc

2026-10-31 19:54

c_schmitz


Details Diff
Fixed issue 19104: Exporting responses of a survey with many questions failed on PostgreSQL with a "Too many columns" error
Dev The test imports its survey under its own ID so it no longer breaks DateTimeForwardBackTest, and switches on identity insert for the timings row on MSSQL
Affected Issues
19104
mod - tests/unit/helpers/admin/export/ExportJoinedColumnsTest.php Diff File

Issue History

Date Modified Username Field Change
2023-09-21 16:56 mferraz New Issue
2023-09-21 16:56 mferraz File Added: limesurvey_survey_988487.lss
2023-09-21 16:56 mferraz Issue Monitored: mferraz
2023-09-21 16:56 mferraz Bug heat 0 => 2
2023-09-26 10:25 mferraz Note Added: 77323
2023-09-26 10:25 mferraz Bug heat 2 => 4
2023-10-17 15:04 gabrieljenik Note Added: 77740
2023-10-17 15:04 gabrieljenik Bug heat 4 => 6
2023-10-23 20:31 gabrieljenik Status new => feedback
2026-10-31 18:56 c_schmitz Changeset attached => LimeSurvey master ec070327
2026-10-31 18:56 c_schmitz Note Added: 87046
2026-10-31 18:56 c_schmitz Assigned To => c_schmitz
2026-10-31 18:56 c_schmitz Status feedback => resolved
2026-10-31 18:56 c_schmitz Resolution open => fixed
2026-10-31 18:56 c_schmitz Bug heat 6 => 8
2026-10-31 19:54 c_schmitz Changeset attached => LimeSurvey master 2b58cdfc
2026-10-31 19:54 c_schmitz Note Added: 87053