View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
04373Bug reportsSurvey editingpublic2010-06-08 21:51
Reporterjrowley Assigned Toc_schmitz  
PriorityurgentSeveritypartial_block 
Status closedResolutionfixed 
Product Version1.90b 
Target Version1.90RC1Fixed in Version1.90RC1 
Summary04373: Error trying to activate a suvey
Description

beta 3

'Call to a member function RecordCount() on a non-object"

Steps To Reproduce

The survey was generated in 1.8, and the database upgraded.

Try to activate a large(200+ questions) survey from an existing survey.

Additional Information

after looking at the code, (admin/activate.php) the root problem is the query is using a text field in the "order by" clause of the query. Text fields are not allowed in an order by in SQL Server 2K8. I removed the text field and progressed further ( next bug).

I noticed that there many results sets where the existence of data is checked, before it is determined if the result set is valid ( i.e. not -1).

TagsNo tags attached.
Attached Files
Bug heat6
Complete LimeSurvey version number (& build)8754
I will donate to the project if issue is resolved
BrowserFirefox
Database type & versionSQL Server 2k8
Server OS (if known)Windows Server 2K8
Webserver software & version (if known)IIS 7
PHP Version5.2.11

Users monitoring this issue

There are no users monitoring this issue.

Activities

Mazi

Mazi

2010-05-29 15:48

updater   ~12025

Machaven, can you test on MS SQL 2008?

Mazi

Mazi

2010-05-29 15:49

updater   ~12026

Please attach a sample survey for testing, thanks!

jrowley

jrowley

2010-06-01 15:32

reporter   ~12057

I am using MS SQL Server 2008 (2K8). This is the same survey for bug # 4374.

machaven

machaven

2010-06-01 21:40

reporter   ~12069

Hi, I am not sure where i'm going to find an sql2k8 server!
I'll see what i can do.

Mazi

Mazi

2010-06-04 01:31

updater   ~12129

Carsten, I think you are the only poor guy having MS SQL installed for testing :-)

jrowley

jrowley

2010-06-04 14:53

reporter   ~12161

I looked into this, and here is what I found. On line 101 (approximately) in admin/activate.php there is a line: "SELECT * FROM {$dbprefix}questions WHERE parent_qid = {$chkrow ['qid']} ORDER BY question_order, question". question is a text datatype which is not allowed in sql server 2008 and fails. The return code from the query is not checked, and the recordCount object in a -1 structure is checked.

Once I removed question from the query it works OK. I am concerned this logic is sprinkled everywhere.

Issue History

Date Modified Username Field Change
2010-05-27 23:42 jrowley New Issue
2010-05-27 23:42 jrowley Status new => assigned
2010-05-27 23:42 jrowley Assigned To => user372
2010-05-29 15:47 Mazi Assigned To user372 => machaven
2010-05-29 15:48 Mazi Target Version => 1.90RC1
2010-05-29 15:48 Mazi Description Updated
2010-05-29 15:48 Mazi Note Added: 12025
2010-05-29 15:49 Mazi Note Added: 12026
2010-05-29 15:49 Mazi Status assigned => feedback
2010-06-01 15:31 jrowley File Added: limesurvey_survey_49736.lss
2010-06-01 15:32 jrowley Note Added: 12057
2010-06-01 15:32 jrowley Status feedback => assigned
2010-06-01 21:40 machaven Note Added: 12069
2010-06-04 01:31 Mazi Assigned To machaven => c_schmitz
2010-06-04 01:31 Mazi Note Added: 12129
2010-06-04 14:53 jrowley Note Added: 12161
2010-06-04 17:55 c_schmitz Status assigned => resolved
2010-06-04 17:55 c_schmitz Fixed in Version => 1.90RC1
2010-06-04 17:55 c_schmitz Resolution open => fixed
2010-06-08 21:51 c_schmitz Status resolved => closed
2010-10-25 00:17 c_schmitz Category Survey Design => Survey design
2019-11-01 17:25 c_schmitz Category Survey design => Survey editing