View Issue Details

This bug affects 1 person(s).
 24
IDProjectCategoryView StatusLast Update
19110Bug reportsDatabase designpublic2024-10-17 20:28
Reporterzufolo441 Assigned Totibor.pacalat  
PrioritynoneSeveritypartial_block 
Status closedResolutionfixed 
Product Version6.2.x 
Summary19110: with MSSQL Lime is unable to activate survey
Description

Hi,
there is a bug in
limesurvey/application/models/SurveyActivator.php
when I try to activate a survey I obtain an error "mssql_drop_coulmn_with_constraints is not defined":

  1. the declaration require_once(DIR . '/../helpers/admin/activate_helper.php'); is missing in file
  2. there is an ortographic error, but because this error is replicated in helpers/admin/activate_helper.php it still works :-)

I added the declaration at row 376 and it works.

Steps To Reproduce

Steps to reproduce

try to activate a survey with MSSQL backend.

TagsNo tags attached.
Bug heat24
Complete LimeSurvey version number (& build)6.2.9
I will donate to the project if issue is resolvedNo
BrowserFirefox 117.0
Database type & versionMicrosoft SQL Server 2012 (SP3-GDR) (KB4019092) - 11.0.6251.0 (X64)
Server OS (if known)Debian 12
Webserver software & version (if known)nginx+php-fpm
PHP Version8.2

Relationships

has duplicate 19229 closedc_schmitz bug in mssql_drop_coulmn_with_constraints 
has duplicate 19566 closedtibor.pacalat Database error when reactivation of deactivated survey 

Users monitoring this issue

There are no users monitoring this issue.

Activities

mfavetti

mfavetti

2023-10-25 09:45

developer   ~77958

reproduced

mfavetti

mfavetti

2023-10-25 10:27

developer   ~77961

master: https://github.com/LimeSurvey/LimeSurvey/pull/3573

mfavetti

mfavetti

2023-10-25 10:27

developer   ~77962

need to check 5.x

mfavetti

mfavetti

2023-10-25 10:55

developer   ~77964

does not appear to affect 5.x

tibor.pacalat

tibor.pacalat

2024-01-16 15:39

administrator   ~79184

Duplicate of https://bugs.limesurvey.org/view.php?id=19344

zufolo441

zufolo441

2024-01-25 08:27

reporter   ~79309

Hi, solution posted in 6.4.3 is partial.

there is still an error in activate_helper.php, row 357:
foreach ($result as $constraintName) {
Yii::app()->db->createCommand('ALTER TABLE [' . $tablename . '] DROP CONSTRAINT "' . $constraintName['constraint_name'] . '"')->execute();
}

CONSTRAINT_NAME must be uppercased:

foreach ($result as $constraintName) {
    Yii::app()->db->createCommand('ALTER TABLE [' . $tablename . '] DROP CONSTRAINT "' . $constraintName['CONSTRAINT_NAME'] . '"')->execute();
}
zufolo441

zufolo441

2024-06-21 11:11

reporter   ~80410

Hi, this bug is still there. Is there some problem to integrate solution I posted here?
I have to manually correct activate_helper.php at every LS update....
This morning with 6.5.13.

Many thanks!

c_schmitz

c_schmitz

2024-09-03 16:58

administrator   ~80883

Just applied another fix

LimeBot

LimeBot

2024-09-09 18:36

administrator   ~80942

Fixed in Release 6.6.3+240909

Related Changesets

LimeSurvey: master 2d2423cb

2024-09-03 18:57

c_schmitz


Details Diff
Fixed issue 19110: Using MSSQL unable to activate survey a second time Affected Issues
19110
mod - application/helpers/admin/activate_helper.php Diff File

Issue History

Date Modified Username Field Change
2023-09-25 12:29 zufolo441 New Issue
2023-10-25 09:38 mfavetti Assigned To => mfavetti
2023-10-25 09:38 mfavetti Status new => assigned
2023-10-25 09:42 mfavetti Assigned To mfavetti =>
2023-10-25 09:43 mfavetti Assigned To => mfavetti
2023-10-25 09:45 mfavetti Note Added: 77958
2023-10-25 09:45 mfavetti File Added: LimeSurvey - Google Chrome 2023-10-25 00-44-11-converted.mp4
2023-10-25 09:45 mfavetti Bug heat 0 => 2
2023-10-25 09:45 mfavetti Status assigned => confirmed
2023-10-25 10:27 mfavetti Note Added: 77961
2023-10-25 10:27 mfavetti Note Added: 77962
2023-10-25 10:55 mfavetti Note Added: 77964
2023-10-25 11:21 mfavetti Assigned To mfavetti => DenisChenu
2023-10-25 11:21 mfavetti Status confirmed => ready for code review
2023-10-26 11:47 DenisChenu Assigned To DenisChenu => tibor.pacalat
2023-10-26 11:47 DenisChenu Status ready for code review => ready for testing
2024-01-16 15:39 tibor.pacalat Status ready for testing => resolved
2024-01-16 15:39 tibor.pacalat Resolution open => fixed
2024-01-16 15:39 tibor.pacalat Note Added: 79184
2024-01-16 15:39 tibor.pacalat Bug heat 2 => 4
2024-01-25 08:27 zufolo441 Note Added: 79309
2024-01-25 08:27 zufolo441 Bug heat 4 => 6
2024-06-21 11:11 zufolo441 Note Added: 80410
2024-09-03 16:58 c_schmitz Changeset attached => LimeSurvey master 2d2423cb
2024-09-03 16:58 c_schmitz Note Added: 80883
2024-09-03 16:58 c_schmitz Bug heat 6 => 8
2024-09-03 17:16 c_schmitz Relationship added has duplicate 19229
2024-09-03 17:16 c_schmitz Bug heat 8 => 16
2024-09-09 18:36 LimeBot Note Added: 80942
2024-09-09 18:36 LimeBot Status resolved => closed
2024-09-09 18:36 LimeBot Bug heat 16 => 18
2024-10-17 20:28 c_schmitz Relationship added has duplicate 19566
2024-10-17 20:28 c_schmitz Bug heat 18 => 24