View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
03847Bug reportsOtherpublic2009-11-28 13:45
ReporterMazi Assigned Tolemeur  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version1.87RC1 
Target Version1.87RC3Fixed in Version1.87RC3 
Summary03847: When exporting token data column headings are not converted
Description

How to reproduce:

  1. Create a survey
  2. Set up a token table
  3. Add an additional column to the token table e.g. "age"
  4. Manually add an entry to the token table
  5. Export tokens

At the CSV file the heading of the additional column should read "age" but it is listed as "attribute_x". When having several additional columns it's impossible to see which information is stored in a certain column so we need the assigned column title.

TagsNo tags attached.
Attached Files
Screenshot.png (10,950 bytes)   
Screenshot.png (10,950 bytes)   
tokens_46588.csv (271 bytes)
Correct_Heading.png (4,631 bytes)   
Correct_Heading.png (4,631 bytes)   
Bug heat6
Complete LimeSurvey version number (& build)7910
I will donate to the project if issue is resolved
BrowserFF3
Database type & versionMySQL 5
Server OS (if known)Win XP Sp 3
Webserver software & version (if known)Apache 2.2
PHP Version5.2

Relationships

related to 03855 closedlemeur Exporting tokens fails when having additional attributes 

Users monitoring this issue

There are no users monitoring this issue.

Activities

user372

2009-11-18 00:14

  ~10129

I can reproduce the issue - screenshot and sample token export file are attached.

lemeur

lemeur

2009-11-21 22:44

developer   ~10183

This is not really a bug but rather a feature request as it was not implemented at all.

Fixing the column names at export time would break token-import as only attribute_1...attribute_n fieldnames can be imported.
So this would also need a fix for token import:

  • we should make sure that the 'Real Name' choosen by the survey admin is compliant with CSV field (we may need to escape it for CSV at export time),
  • we would need to update the survey table at token import because this is where the token description are recorded
  • we would need to cope with multiple import of CSV files that may not have the same token attributes columns: in this case we should decide what to do for token description (override, merge...).

This is not impossible, but is clearly a feature request and not a bug.

lemeur

lemeur

2009-11-21 22:47

developer   ~10184

Matador,
I can't see the Feature Request project anymore ?
Where to move this ticket then ?

TIA,
Thibault

Mazi

Mazi

2009-11-22 12:01

updater   ~10194

Thibault, thanks for your feedback. From the user point of view it's really a problem if your columns are named "attribute_1, attribute_2, ..." after export because when having several columns you might not realy know what data is stored at each column.

I suggest to:
a) export

  • Export columns names

b) import

  • Check if the column names of the CSV file exist in the token table. If so import them according to the headings. Attribute description in survey table should match import file headings.
  • If the heading names do not match show a warning and import them in the order they are listed at the import file. we should not override the attribute description.
lemeur

lemeur

2009-11-22 14:51

developer   ~10198

Mzi, your proposal would add extra complexity to token import.

I propose a simpler solution:

a) export

  • Exports attribute_x code with an extra <attr description> text

b) import

  • strip any <attr description> and import a usual.

See rev 7956.

lemeur

lemeur

2009-11-22 14:52

developer   ~10199

Setting this as resolved, please re-open if it's really not satisfactory.

Issue History

Date Modified Username Field Change
2009-11-17 16:56 Mazi New Issue
2009-11-17 16:56 Mazi Status new => assigned
2009-11-17 16:56 Mazi Assigned To => user372
2009-11-17 16:56 Mazi LimeSurvey build number => 7910
2009-11-17 16:56 Mazi Browser => FF3
2009-11-17 16:56 Mazi Database & DB-Version => MySQL 5
2009-11-17 16:56 Mazi Operating System (Server) => Win XP Sp 3
2009-11-17 16:56 Mazi Webserver => Apache 2.2
2009-11-17 16:56 Mazi PHP Version => 5.2
2009-11-18 00:14 user372 Note Added: 10129
2009-11-18 00:14 user372 File Added: Screenshot.png
2009-11-18 00:14 user372 File Added: tokens_46588.csv
2009-11-18 00:15 user372 File Added: Correct_Heading.png
2009-11-18 00:16 user372 Assigned To user372 => lemeur
2009-11-18 00:16 user372 Target Version => 1.87RC3
2009-11-18 16:36 Mazi Relationship added related to 03855
2009-11-21 22:44 lemeur Note Added: 10183
2009-11-21 22:47 lemeur Note Added: 10184
2009-11-21 22:47 lemeur Status assigned => feedback
2009-11-22 12:01 Mazi Note Added: 10194
2009-11-22 14:51 lemeur Note Added: 10198
2009-11-22 14:52 lemeur Note Added: 10199
2009-11-22 14:52 lemeur Status feedback => resolved
2009-11-22 14:52 lemeur Fixed in Version => 1.87RC3
2009-11-22 14:52 lemeur Resolution open => fixed
2009-11-28 13:45 c_schmitz Status resolved => closed
2010-05-06 10:27 c_schmitz Category Import / Export => (No Category)