View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
03940Bug reportsConditionspublic2009-12-31 00:52
Reporteruser5205Assigned Tolemeur  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version1.86 
Fixed in Version1.87 
Summary03940: Question Conditions Based on a Token Attribute do not Survive an Export Import Cycle
Description

Importing a survey with questions that have conditions based on token attributes does not recreate the question conditions on the import.

Additional Information

See the attached file for a sample survey

Tagsconditions, import
Attached Files
Bug heat6
Complete LimeSurvey version number (& build)7697
I will donate to the project if issue is resolved
Browser
Database type & versionmysql Ver 14.12 Distrib 5.0.51a, for debian-linux-gnu
Server OS (if known)Linux version 2.6.26-2-686 (Debian 2.6.26-19lenny2)
Webserver software & version (if known)Apache/2.2.9 (Debian)
PHP VersionPHP Version 5.2.6-1+lenny4

Users monitoring this issue

There are no users monitoring this issue.

Activities

user372

2009-12-03 22:48

  ~10426

@ lithium: If I remember correctly it's not possible to set conditions based on tokens after import correctly ==> have a look at the notes of Lemeur in 03798

@ Lemeur: Am I right about import of a survey with conditions based on tokens?

@ Lemeur: If I imported the attached survey on my installation (latest revision from SVN), activate the survey and DON'T set to use tokens and run the survey ==> I get the following error:
Fatal error: Call to a member function RecordCount() on a non-object in /home/.sites/962/site989/web/limesurvey/common.php on line 6908

lemeur

lemeur

2009-12-04 14:50

developer   ~10447

This ticket is certainly that it is a duplicate of 03798.

Sorry Matador I don't understand your sentence "If I remember correctly it's not possible to set conditions based on tokens after import correctly".

The bug in 3798 prevented a correct import of surveys with conditions based on tokens. Once the survey has been incorrectly imported (conditions have been tampered with by the import system), it is not possible to fix it with the LimeSurvey GUI => you have to delete the survey, upgrade the LS installation, and then import again the survey from a correct survey structure (one that haven't been imported yet).

However, it is possible to set new conditions on tokens on a survey that has just been imported.

Hope this helps,
Thibault

user372

2009-12-04 20:41

  ~10464

@ lemeur: I meant, that conditions based on tokens are invalid and are not working directly after importing a survey structure.

@ lemeur: Can you reproduce the error message "Fatal error: Call to a member function RecordCount() on a non-object in..." and fix it?

user5205

2009-12-04 22:00

  ~10466

"Once the survey has been incorrectly imported (conditions have been tampered with by the import system), it is not possible to fix it with the LimeSurvey GUI"

I'm not sure what you mean by this. Any conditions based on tokens after import just seemed to not exist. To fix it I manually created a token table and recreated the conditions. Do you mean they are hiding in the db or somewhere else invisible to the GUI?

Would it be reasonable to have Limesurvey automatically initialize a token table when you import a survey with conditions based on tokens? Or is a non-existent token table not the root of the problem.

lemeur

lemeur

2009-12-05 08:52

developer   ~10472

[Quote]Do you mean they are hiding in the db or somewhere else invisible to the GUI?[/Quote]

Yes exactly.

[Quote]is a non-existent token table not the root of the problem.[/Quote]
Non existent token is not the cause of the Import problem.
In LS 1.87 you can safely import surveys having conditions on tokens even if the token table doesn't exist ==> of course if you don't set the token table conditions won't work... hence the RecordCount error reported by Matador (at least it seems to be).

Thibault

lemeur

lemeur

2009-12-19 09:21

developer   ~10607

The error reported by Matador is fixed in rev 8180.

Issue History

Date Modified Username Field Change
2009-12-02 23:00 user5205 New Issue
2009-12-02 23:00 user5205 Status new => assigned
2009-12-02 23:00 user5205 Assigned To => user372
2009-12-02 23:00 user5205 File Added: limesurvey_survey_85851.csv
2009-12-02 23:00 user5205 LimeSurvey build number => 7697
2009-12-02 23:00 user5205 Database & DB-Version => mysql Ver 14.12 Distrib 5.0.51a, for debian-linux-gnu
2009-12-02 23:00 user5205 Operating System (Server) => Linux version 2.6.26-2-686 (Debian 2.6.26-19lenny2)
2009-12-02 23:00 user5205 Webserver => Apache/2.2.9 (Debian)
2009-12-02 23:00 user5205 PHP Version => PHP Version 5.2.6-1+lenny4
2009-12-02 23:01 user5205 Tag Attached: conditions
2009-12-02 23:01 user5205 Tag Attached: import
2009-12-03 22:48 user372 Note Added: 10426
2009-12-03 22:48 user372 Assigned To user372 => lemeur
2009-12-04 14:50 lemeur Note Added: 10447
2009-12-04 15:42 lemeur Status assigned => feedback
2009-12-04 20:41 user372 Note Added: 10464
2009-12-04 22:00 user5205 Note Added: 10466
2009-12-05 08:52 lemeur Note Added: 10472
2009-12-19 09:21 lemeur Note Added: 10607
2009-12-19 09:21 lemeur Status feedback => resolved
2009-12-19 09:21 lemeur Fixed in Version => 1.87
2009-12-19 09:21 lemeur Resolution open => fixed
2009-12-31 00:52 c_schmitz Status resolved => closed