View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
09745Bug reportsStatisticspublic2016-08-17 16:47
Reporteruser40445Assigned Toc_schmitz  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version2.06+ 
Fixed in Version2.50.x 
Summary09745: Statistics graphs are incorrect for questions with multiple identical answers.
Description

If I add a question which has multiple identical answers (useful with empty labels when asking for a range where you only label the extremes), the statistics graph is wrong. The reason for this is that the labels are added into a hashtable $lbl in statistics_helper.php, thus overwriting one another if they are the same.
$lbl should really be an array, not a hash table.

Steps To Reproduce

Add a question where multiple answers are identical. Create a statistics graph.

TagsNo tags attached.
Attached Files
wrong-stats.jpg (73,521 bytes)   
wrong-stats.jpg (73,521 bytes)   
Bug heat6
Complete LimeSurvey version number (& build)150310
I will donate to the project if issue is resolvedNo
BrowserBrowser-independent
Database type & versionMySQL
Server OS (if known)RHEL 7
Webserver software & version (if known)Apache 2
PHP VersionPHP 5.4

Users monitoring this issue

aesteban, Vieli1979

Activities

c_schmitz

c_schmitz

2015-07-31 13:06

administrator   ~32854

Dev Reminder:

foreach ($array as list($a, $b))

Issue History

Date Modified Username Field Change
2015-07-02 17:13 user40445 New Issue
2015-07-02 17:13 user40445 File Added: wrong-stats.jpg
2015-07-03 00:53 aesteban Issue Monitored: aesteban
2015-07-28 11:52 Vieli1979 Issue Monitored: Vieli1979
2015-07-30 11:26 c_schmitz Assigned To => c_schmitz
2015-07-30 11:26 c_schmitz Status new => assigned
2015-07-31 13:06 c_schmitz Note Added: 32854
2015-07-31 13:07 c_schmitz Assigned To c_schmitz =>
2015-07-31 13:07 c_schmitz Status assigned => acknowledged
2015-07-31 13:07 c_schmitz Target Version => 3.0
2016-08-17 16:47 c_schmitz Status acknowledged => closed
2016-08-17 16:47 c_schmitz Assigned To => c_schmitz
2016-08-17 16:47 c_schmitz Resolution open => fixed
2016-08-17 16:47 c_schmitz Fixed in Version => 2.5
2021-08-05 11:56 guest Bug heat 2 => 6