View Issue Details

This bug affects 1 person(s).
 2
IDProjectCategoryView StatusLast Update
06596Bug reportsSurvey participants (Tokens)public2012-10-05 15:54
Reportergalthaus Assigned Totrougakoss  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version2.00+ 
Fixed in Version2.00+ 
Summary06596: Cant send invitation email with SQL DB
Description

Get an error when sending email:
CDbCommand failed to execute the SQL statement: SQLSTATE[42000]: [Microsoft][SQL Server Native Client 11.0][SQL Server]Incorrect syntax near 'LIMIT'.. The SQL statement executed was: SELECT * FROM tokens_689348 WHERE ((completed ='N') or (completed='')) AND token <> '' AND email <> '' AND ((sent = 'N') or (sent = '')) AND emailstatus = 'OK' AND tid IN ('5') ORDER BY tid LIMIT 1

Steps To Reproduce

Generate token for Survey and send email invitation

Additional Information

As i know the keyword LIMIT is not supported by MSSQL

TagsNo tags attached.
Bug heat2
Complete LimeSurvey version number (& build)120926
I will donate to the project if issue is resolvedNo
BrowserIE
Database type & versionSQL 2008
Server OS (if known)W2008 R2
Webserver software & version (if known)IIS 7
PHP Version5.3.13

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2012-09-27 10:17

administrator   ~20838

Spiros, it would be much better to replace this with a ActiveRecord query which supports (non-DB specific) limit, too. Can you take care of this?

c_schmitz

c_schmitz

2012-10-05 15:44

administrator   ~21088

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

c_schmitz

c_schmitz

2012-10-05 15:45

administrator   ~21089

Very nice patch! Thank you very much.

c_schmitz

c_schmitz

2012-10-05 15:54

administrator   ~21092

New build 1201006 released.

Related Changesets

LimeSurvey: master c3b88a52

2012-10-05 08:24

trougakoss


Details Diff
Fixed issue 06596: Cant send invitation email with SQL DB
Dev: Changed findUninvited function in Token_dynamic to use CActiveRecord (non-DB specific)
Dev: Changed building of parameters to take into account the CActiveRecord
Affected Issues
06596
mod - application/controllers/admin/remotecontrol.php Diff File
mod - application/controllers/admin/tokens.php Diff File
mod - application/models/Tokens_dynamic.php Diff File

LimeSurvey: master 3cc692d6

2012-10-05 08:44

c_schmitz


Details Diff
Merge pull request #49 from trougakoss/Yii

Fixed issue 06596: Can't send invitation email with SQL DB
Affected Issues
06596
mod - application/controllers/admin/remotecontrol.php Diff File
mod - application/controllers/admin/tokens.php Diff File
mod - application/models/Tokens_dynamic.php Diff File

Issue History

Date Modified Username Field Change
2012-09-27 09:27 galthaus New Issue
2012-09-27 10:14 c_schmitz Assigned To => trougakoss
2012-09-27 10:14 c_schmitz Status new => assigned
2012-09-27 10:17 c_schmitz Note Added: 20838
2012-10-05 15:44 trougakoss Changeset attached => LimeSurvey master c3b88a52
2012-10-05 15:44 c_schmitz Changeset attached => LimeSurvey master 3cc692d6
2012-10-05 15:44 c_schmitz Note Added: 21088
2012-10-05 15:44 c_schmitz Assigned To trougakoss => c_schmitz
2012-10-05 15:44 c_schmitz Resolution open => fixed
2012-10-05 15:45 c_schmitz Assigned To c_schmitz => trougakoss
2012-10-05 15:45 c_schmitz Status assigned => resolved
2012-10-05 15:45 c_schmitz Fixed in Version => 2.00+
2012-10-05 15:45 c_schmitz Note Added: 21089
2012-10-05 15:54 c_schmitz Note Added: 21092
2012-10-05 15:54 c_schmitz Status resolved => closed
2016-12-08 10:39 c_schmitz Category Tokens => Survey participants (Tokens)