Skip to content

Commit

Permalink
Dev: parent_qid should compare to 0, not NULL, because it is DEFAULT …
Browse files Browse the repository at this point in the history
…0 NOT NULL
  • Loading branch information
olleharstedt committed Dec 14, 2015
1 parent fa79b8b commit 43f2d44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion application/models/Question.php
Original file line number Diff line number Diff line change
Expand Up @@ -775,7 +775,7 @@ public function search()
);

$criteria = new CDbCriteria;
$criteria->condition="t.sid=:surveyid AND t.language=:language AND parent_qid=NULL";
$criteria->condition="t.sid=:surveyid AND t.language=:language AND parent_qid=0";
$criteria->params=(array(':surveyid'=>$this->sid,':language'=>$this->language));
$criteria->join='LEFT JOIN {{groups}} AS groups ON ( groups.gid = t.gid AND t.language = groups.language )';

Expand Down

0 comments on commit 43f2d44

Please sign in to comment.