View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
04729Bug reportsSurvey participants (Tokens)public2010-11-17 01:03
Reporteruser10583Assigned Toc_schmitz  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version1.90+ 
Fixed in Version1.90+ 
Summary04729: SQL Syntax error when initialising token for survey
Description

When I attempt to initialise tokens for any survey, I receive the following error:

Token table could not be created.
Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'TYPE=myISAM CHARACTER SET utf8 COLLATE utf8_unicode_ci' at line 17
CREATE TABLE tokens_84713 (
tid INT NOT NULL AUTO_INCREMENT,
firstname VARCHAR(40),
lastname VARCHAR(40),
email TEXT,
emailstatus TEXT,
token VARCHAR(36),
language VARCHAR(25),
sent VARCHAR(17) DEFAULT 'N',
remindersent VARCHAR(17) DEFAULT 'N',
remindercount INT DEFAULT 0,
completed VARCHAR(17) DEFAULT 'N',
validfrom DATETIME,
validuntil DATETIME,
mpid INTEGER,
PRIMARY KEY (tid)
)TYPE=myISAM CHARACTER SET utf8 COLLATE utf8_unicode_ci

This is on a default installation of MySQL. No modifications/customizations have been done.

Steps To Reproduce
  • Select survey
  • Click 'Token mangement'
  • Click 'Initialise tokens'
Additional Information

PHP 5.2.14 with Suhosin-Patch 0.9.7 (cli)

mysql Ver 14.14 Distrib 5.5.6-rc, for portbld-freebsd8.0 (i386) using 5.2

TagsNo tags attached.
Attached Files
tokens.php (159,431 bytes)
Bug heat4
Complete LimeSurvey version number (& build)9406
I will donate to the project if issue is resolvedNo
BrowserIE8
Database type & versionMySQL v.5.2
Server OS (if known)FreeBSD 8.0-RC1
Webserver software & version (if known)Apache 2.2
PHP VersionPHP v.5.2

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2010-11-10 16:49

administrator   ~13482

I can run the SQL statement

CREATE TABLE tokens_84713 (
tid INT NOT NULL AUTO_INCREMENT,
firstname VARCHAR(40),
lastname VARCHAR(40),
email TEXT,
emailstatus TEXT,
token VARCHAR(36),
language VARCHAR(25),
sent VARCHAR(17) DEFAULT 'N',
remindersent VARCHAR(17) DEFAULT 'N',
remindercount INT DEFAULT 0,
completed VARCHAR(17) DEFAULT 'N',
validfrom DATETIME,
validuntil DATETIME,
mpid INTEGER,
PRIMARY KEY (tid)
)TYPE=myISAM CHARACTER SET utf8 COLLATE utf8_unicode_ci

perfectly fine on mySQL server here.
Maybe some bug with your mySQL server?

c_schmitz

c_schmitz

2010-11-10 17:09

administrator   ~13484

I am quite certain that this is a bug with your MySQL server, missing DB engine or your mySQL is just too old.
There is no mySQL 5.2 btw.

user10583

2010-11-11 22:19

  ~13504

I am running v.5.5.6 MySQL. I apologize for the mixup. But 'Type' has been obsolete for a while now, and this query works with using 'engine' instead of 'type'. Is there anywhere that I can change the script for this query?

c_schmitz

c_schmitz

2010-11-11 23:03

administrator   ~13505

Attached fixed file.

c_schmitz

c_schmitz

2010-11-17 01:03

administrator   ~13544

Fix released in latest 1.90+ version.

Issue History

Date Modified Username Field Change
2010-11-09 17:08 user10583 New Issue
2010-11-10 16:48 c_schmitz Assigned To => c_schmitz
2010-11-10 16:48 c_schmitz Status new => assigned
2010-11-10 16:49 c_schmitz Note Added: 13482
2010-11-10 17:09 c_schmitz Note Added: 13484
2010-11-10 17:09 c_schmitz Status assigned => closed
2010-11-10 17:09 c_schmitz Resolution open => no change required
2010-11-11 22:19 user10583 Note Added: 13504
2010-11-11 22:19 user10583 Status closed => feedback
2010-11-11 22:19 user10583 Resolution no change required => reopened
2010-11-11 23:03 c_schmitz Note Added: 13505
2010-11-11 23:03 c_schmitz File Added: tokens.php
2010-11-11 23:04 c_schmitz Status feedback => resolved
2010-11-11 23:04 c_schmitz Fixed in Version => 1.90+
2010-11-11 23:04 c_schmitz Resolution reopened => fixed
2010-11-17 01:03 c_schmitz Note Added: 13544
2010-11-17 01:03 c_schmitz Status resolved => closed
2016-12-08 10:39 c_schmitz Category Tokens => Survey participants (Tokens)