View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
07633Bug reportsCentral participant databasepublic2013-03-11 15:03
Reporterpnadam Assigned Toc_schmitz  
PrioritynormalSeveritypartial_block 
Status closedResolutionfixed 
Product Version2.00+ 
Fixed in Version2.00+ 
Summary07633: Importing CSV of respondants presents attribute-mapping interface, but does not map contents to attributes
Description

I have added four attributes to my central participant database: Unique Code (an internal ID for a respondant), Home Tel No, Mobile Tel No, and Work Tel No.

I have then taken a set of real respondant data to test this, turned it into a CSV, and attempted to upload the CSV to the central participant database.

Three (I think) updates ago (I have updated twice: today (one update) and last week or the week before (two updates)), this worked flawlessly. Now I get no information added to the attributes, despite being given the interface for mapping CSV columns to CPD attributes.

I have attached four images to illustrate the problem: the empty CPD with attributes, the interface it presents me for mapping CSV columns to CPD attributes (with how I have set it up), the data (censored) that I'm trying to load, and the CPD table after the load (note the empty attributes).

Steps To Reproduce
  1. Open central participant table
  2. Select to import data to CPD via .CSV
  3. Select CSV of data
    (4. Deselect to ignore rows without emails) <- may not be necessary, but this is what I'm doing because I want those in the database
  4. Upload
  5. Assign columns to attributes (note: in my case I have a lot of columns in the CSV but am only assigning four to attributes).
  6. Complete
  7. Observe CPD rows that do not have attribute data completed.
TagsNo tags attached.
Attached Files
bug report composite.png (169,411 bytes)
data censored.csv (22,081 bytes)
Bug heat4
Complete LimeSurvey version number (& build)130226
I will donate to the project if issue is resolvedNo
BrowserFirefox 21a, Chromium 6.0.472.63
Database type & versionMySQL 5.5
Server OS (if known)DB: Debian 6.0.2
Webserver software & version (if known)Apache 2.2.16
PHP Version5.3.21

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2013-03-04 21:35

administrator   ~24519

Please attach the .csv file you are trying to import.

pnadam

pnadam

2013-03-05 11:44

reporter   ~24541

Last edited: 2013-03-05 11:46

I've attached a censored version of the file (real contents are too sensitive), which I've tested again to make sure it wasn't the contents of the file.

What I found is that this time it did attach data correctly to the UniqueCode attribute that I've added (but not the other three attributes). When I checked the CSV I found that yesterday, while I was trying to see how to upload a CSV to a survey-specific tokens table, I renamed this column, which is in the screenshot I provided here named as 'Token', to 'uniquecode'.

Thus, conclusion is that the system is ignoring what I specify in the column-mapping interface if the column in the CSV is not named the same as the column to which I am mapping it (case insensitive).

I'm going to experiment a little more and see what happens in different combinations of mapping, not mapping, matching spelling, and not matching spelling. Will report back.

pnadam

pnadam

2013-03-05 12:05

reporter   ~24542

Here are my findings:

Uploaded the CSV with the relevant columns named as follows

Attribute Name - CSV Column Name
UniqueCode - uniquecode
Telephone - telephone
Mobile - mobile
WorkPhone - Work Tel No

I didn't map anything to UniqueCode, but I did map telephone to Telephone, mobile to Mobile, and Work Tel No to Workphone.

UniqueCode came out blank, as expected, Telephone and Mobile came out with the correct data imported, and WorkPhone came out blank.

This confirms what I thought in the previous note; that the mapping is ignored if the CSV column name does not match (case insensitively) the name of the attribute.

This looks to be the same issue with survey-specific token tables, wherein importing a CSV only auto-maps columns if in the CSV the columns are named 'attribute_1', 'attribute_2', etc., and not if they are named alike to the attribute description.

c_schmitz

c_schmitz

2013-03-06 16:08

administrator   ~24567

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

c_schmitz

c_schmitz

2013-03-07 22:39

administrator   ~24578

Fix committed to 2.05 branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=11798

c_schmitz

c_schmitz

2013-03-11 15:03

administrator   ~24625

2.00+ build 130311 released

Related Changesets

LimeSurvey: master 5b110718

2013-03-06 15:08:07

c_schmitz

Details Diff
Fixed issue 07633: Importing CSV of respondents presents attribute-mapping interface, but does not map contents to attributes Affected Issues
07633
mod - application/controllers/admin/participantsaction.php Diff File
mod - application/views/admin/participants/attributeMapCSV_view.php Diff File

LimeSurvey: 2.05 112ca720

2013-03-06 15:08:07

c_schmitz

Details Diff
Fixed issue 07633: Importing CSV of respondents presents attribute-mapping interface, but does not map contents to attributes Affected Issues
07633
mod - application/controllers/admin/participantsaction.php Diff File
mod - application/views/admin/participants/attributeMapCSV_view.php Diff File

Issue History

Date Modified Username Field Change
2013-03-04 13:54 pnadam New Issue
2013-03-04 13:54 pnadam Status new => assigned
2013-03-04 13:54 pnadam Assigned To => jcleeland
2013-03-04 13:54 pnadam File Added: bug report composite.png
2013-03-04 21:35 c_schmitz Assigned To jcleeland => c_schmitz
2013-03-04 21:35 c_schmitz Note Added: 24519
2013-03-04 21:35 c_schmitz Status assigned => feedback
2013-03-05 11:44 pnadam Note Added: 24541
2013-03-05 11:44 pnadam Status feedback => assigned
2013-03-05 11:44 pnadam File Added: data censored.csv
2013-03-05 11:46 pnadam Note Edited: 24541
2013-03-05 12:05 pnadam Note Added: 24542
2013-03-06 16:08 c_schmitz Status assigned => resolved
2013-03-06 16:08 c_schmitz Fixed in Version => 2.00+
2013-03-06 16:08 c_schmitz Resolution open => fixed
2013-03-06 16:08 c_schmitz Changeset attached => LimeSurvey master 5b110718
2013-03-06 16:08 c_schmitz Note Added: 24567
2013-03-07 22:39 c_schmitz Changeset attached => LimeSurvey 2.05 112ca720
2013-03-07 22:39 c_schmitz Note Added: 24578
2013-03-11 15:03 c_schmitz Note Added: 24625
2013-03-11 15:03 c_schmitz Status resolved => closed