View Issue Details

This issue affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
20355Bug reportsComfortUpdatepublic2025-11-24 16:27
Reportermsvojsik Assigned Tolajosarpad  
PrioritynoneSeveritycrash 
Status closedResolutionfixed 
Product Version6.6.x 
Summary20355: Not able to upgrade from Limesurvey community version 6.15.1 to newer version when running on MSSQL DBMS
Description

While trying update to newer version, the update fails because of T-SQL syntax error with the following details:
Syntax error in upgrade script for MSSQL DBMS.
Upgrade fails when trying to upgrade from DB version 633 (Limesurvey 6.15.0) or 634 (Limesurvey 6.15.1) to 636 (Limesurvey 6.15.4 or newer) with the following error:

CDbCommand failed to execute the SQL statement: SQLSTATE[42000]: [Microsoft][ODBC Driver 18 for SQL Server][SQL Server]Incorrect syntax near the keyword 'backup'.

\application\helpers\update\updates\Update_636.php, line 20

Steps To Reproduce

Steps to reproduce

Upgrade fails when trying to upgrade from DB version 633 (Limesurvey 6.15.0) or 634 (Limesurvey 6.15.1) to 636 (Limesurvey 6.15.4 or newer)

Expected result

successfull upgrade

Actual result

upgrade fails

TagsNo tags attached.
Bug heat6
Complete LimeSurvey version number (& build)6.15.0 (build 250623)
I will donate to the project if issue is resolvedYes
Browser
Database type & versionMSSQL Server 2022
Server OS (if known)Windows server 2022
Webserver software & version (if known)IIS 10
PHP Version8.3.27

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2025-11-21 23:23

administrator   ~83911

@msvojsik I think somewhere you have a table in your database which you created/rename manually containing the word 'token' and 'backup' or similar. like 'token_backup_12345'

If you remove that table the update should work.

c_schmitz

c_schmitz

2025-11-24 12:34

administrator   ~83915

PR https://github.com/LimeSurvey/LimeSurvey/pull/4564

lajosarpad

lajosarpad

2025-11-24 12:36

developer   ~83916

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

msvojsik

msvojsik

2025-11-24 16:26

reporter   ~83919

@c_schmitz you're right, thanks for the tip. I can confirm, that once the table was removed from DB, update was successfull.

msvojsik

msvojsik

2025-11-24 16:27

reporter   ~83920

resolved by using the provided advice, thanks

Related Changesets

LimeSurvey: master 63e756d9

2025-11-24 12:36

lajosarpad

Committer: GitHub


Details Diff
Fixed issue 20355: Not able to upgrade to newer version when running on MSSQL DBMS Affected Issues
20355
mod - application/helpers/update/updates/Update_636.php Diff File

Issue History

Date Modified Username Field Change
2025-11-18 10:49 msvojsik New Issue
2025-11-21 23:23 c_schmitz Note Added: 83911
2025-11-21 23:23 c_schmitz Bug heat 0 => 2
2025-11-21 23:24 c_schmitz Assigned To => p_teichmann
2025-11-21 23:24 c_schmitz Status new => assigned
2025-11-24 12:34 c_schmitz Assigned To p_teichmann => lajosarpad
2025-11-24 12:34 c_schmitz Note Added: 83915
2025-11-24 12:36 lajosarpad Changeset attached => LimeSurvey master 63e756d9
2025-11-24 12:36 lajosarpad Note Added: 83916
2025-11-24 12:36 lajosarpad Status assigned => resolved
2025-11-24 12:36 lajosarpad Resolution open => fixed
2025-11-24 12:36 lajosarpad Bug heat 2 => 4
2025-11-24 16:26 msvojsik Note Added: 83919
2025-11-24 16:26 msvojsik Bug heat 4 => 6
2025-11-24 16:27 msvojsik Status resolved => closed
2025-11-24 16:27 msvojsik Note Added: 83920