View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
08496Bug reportsCentral participant databasepublic2014-01-25 17:22
Reporterduvemyster Assigned Totpartner  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version2.00+ 
Fixed in Version2.05+ 
Summary08496: Undefined attributes in Central Participant Database
Description

When utilizing a token table to both add participants to the central participant database and add 2 or more attributes to the central participant database at the same time, then I'm running into an error message with undefined attributes being inserted in-between each new attribute created.

Steps To Reproduce
  1. List a token table with at least two user-defined attributes.
  2. Select one or more records then "Add participants to central database"
  3. Drag at least two attributes to "Participant attributes to create"
  4. Continue
  5. Internal Server Error - CBdCommand failed to execute the SQL statement: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntzx; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
  6. Open "Attribute management" in the Central Participants Database
  7. Note that an "undefined" attribute is added in between each new attribute added.
Additional Information

I overcame this by deleting the undefined attributes and then repeating with the attributes mapped.

TagsNo tags attached.
Attached Files
token_bug_1.png (35,517 bytes)   
token_bug_1.png (35,517 bytes)   
Bug heat4
Complete LimeSurvey version number (& build)Version 2.00+ Build 131206
I will donate to the project if issue is resolvedNo
BrowserGoogle Chrome Version 31.0.1650.63 m
Database type & versionMySQL 5.1
Server OS (if known)Linux
Webserver software & version (if known)Apache/2.2
PHP Version5.4.10

Relationships

related to 08083 closedc_schmitz using token:attribute_cpdb_X in question gives unknown variable 

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2014-01-17 13:36

administrator   ~27947

The issue is here the difficult pairing process, especially for attributes to be created. When dragging to the 'Attributes to be created' box you can easily drop it on an existing element there in the same box or above it or unpair the existing one - which all lead to the erratic behaviour when submitted.

Tony, this is IMHO a GUI issue. It should not be possible to drop an element at the wrong place. Can you take a look at it and prevent invalid drops by adjusting the JS? I know it is a bit tedious because of the weird script but as you are king of JS I feel you are the roght one to ask.

tpartner

tpartner

2014-01-17 21:41

partner   ~27975

Before I start on the JavaScript, I'd like to point out another bug in 2.05.

After initially creating a token table with a couple of attributes and then adding one of the attributes to the CPDB, that attribute in the token table loses its label and the values are moved.

See attache image - token_bug_1.png

tpartner

tpartner

2014-01-18 22:27

partner   ~27995

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

tpartner

tpartner

2014-01-18 22:37

partner   ~27996

Hi Carsten, I have scrapped all of the jQuery UI Sortable stuff and associated alerts (because these items aren't really sortable) and used Draggable/Droppable instead. The controls on the droppables should prevent misplacing the dragged items without pesky alerts.

Please test and, if you find it suitable, we should do the same for attributeMapCSV.js.

c_schmitz

c_schmitz

2014-01-19 16:28

administrator   ~28005

Hello Tony,
this looks very good to me - thank you! Small thing missing: Proper mouse cursor when hovering over drag and drop items.
Please apply these changes to attributeMapCSV, too.
Thank you again!

c_schmitz

c_schmitz

2014-01-19 16:30

administrator   ~28006

Btw, can you make the options ' Overwrite existing attribute values if a participant already exists?' and 'Make these mappings automatic in future' align to the left? Center align in gringegreen looks weird.

tpartner

tpartner

2014-01-19 17:19

partner   ~28008

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

tpartner

tpartner

2014-01-19 17:21

partner   ~28009

Okay, back to you :)

c_schmitz

c_schmitz

2014-01-19 20:25

administrator   ~28012

Will fix the remaining issue in 08083

c_schmitz

c_schmitz

2014-01-25 17:22

administrator   ~28157

2.05+ Build 140125 released

Related Changesets

LimeSurvey: master 9eeb7f16

2014-01-18 21:27:30

tpartner

Details Diff
Fixed issue 08496: Undefined attributes in Central Participant Database
Dev Changed interface from jQuery UI sortable to jQuery UI Draggable
Dev Fixed up invalid HTML
Dev Cleaned up styles and removed inline stuff
Affected Issues
08496
mod - application/views/admin/participants/attributeMapToken_view.php Diff File
mod - scripts/admin/attributeMapToken.js Diff File
mod - styles/blobblueish/attributeMapToken.css Diff File
mod - styles/darkblue/attributeMapToken.css Diff File
mod - styles/gringegreen/attributeMapToken.css Diff File

LimeSurvey: master 79b4b64e

2014-01-19 16:19:15

tpartner

Details Diff
Fixed issue 08496: Undefined attributes in Central Participant Database
Dev Minor layout and style changes
Affected Issues
08496
mod - application/views/admin/participants/attributeMapToken_view.php Diff File
mod - styles/blobblueish/attributeMapToken.css Diff File
mod - styles/darkblue/attributeMapToken.css Diff File
mod - styles/gringegreen/attributeMapToken.css Diff File

Issue History

Date Modified Username Field Change
2013-12-30 20:28 duvemyster New Issue
2014-01-15 12:25 c_schmitz Assigned To => c_schmitz
2014-01-15 12:25 c_schmitz Status new => assigned
2014-01-17 13:33 c_schmitz Assigned To c_schmitz => tpartner
2014-01-17 13:36 c_schmitz Note Added: 27947
2014-01-17 21:41 tpartner Note Added: 27975
2014-01-17 21:42 tpartner File Added: token_bug_1.png
2014-01-18 22:27 tpartner Changeset attached => LimeSurvey master 9eeb7f16
2014-01-18 22:27 tpartner Note Added: 27995
2014-01-18 22:27 tpartner Resolution open => fixed
2014-01-18 22:37 tpartner Note Added: 27996
2014-01-18 22:37 tpartner Assigned To tpartner => c_schmitz
2014-01-19 16:26 c_schmitz Assigned To c_schmitz => tpartner
2014-01-19 16:28 c_schmitz Note Added: 28005
2014-01-19 16:30 c_schmitz Note Added: 28006
2014-01-19 17:19 tpartner Changeset attached => LimeSurvey master 79b4b64e
2014-01-19 17:19 tpartner Note Added: 28008
2014-01-19 17:21 tpartner Note Added: 28009
2014-01-19 17:21 tpartner Assigned To tpartner => c_schmitz
2014-01-19 20:24 c_schmitz Relationship added related to 08083
2014-01-19 20:25 c_schmitz Note Added: 28012
2014-01-19 20:25 c_schmitz Status assigned => resolved
2014-01-19 20:25 c_schmitz Fixed in Version => 2.05+
2014-01-19 20:25 c_schmitz Assigned To c_schmitz => tpartner
2014-01-25 17:22 c_schmitz Note Added: 28157
2014-01-25 17:22 c_schmitz Status resolved => closed