diff --git a/lib/classes/module/report/sqldownload.class.php b/lib/classes/module/report/sqldownload.class.php index f8959738bb..8cf47c6e65 100644 --- a/lib/classes/module/report/sqldownload.class.php +++ b/lib/classes/module/report/sqldownload.class.php @@ -70,8 +70,9 @@ class module_report_sqldownload extends module_report_sql implements module_repo $stmt->execute($this->params); $this->total_row = $stmt->rowCount(); $stmt->closeCursor(); - if ($this->enable_limit) + if ($this->enable_limit) { $this->sql .= $this->filter->getLimitFilter() ? : ''; + } } else { $name = $this->groupby; $field = $this->getTransQuery($this->groupby); @@ -144,9 +145,9 @@ class module_report_sqldownload extends module_report_sql implements module_repo $this->total = $stmt->rowCount(); $stmt->closeCursor(); - if ($this->enable_limit) + if ($this->enable_limit) { $this->sql .= $this->filter->getLimitFilter() ? : ''; - + } } return $this; diff --git a/lib/classes/module/report/sqlquestion.class.php b/lib/classes/module/report/sqlquestion.class.php index 91fb69d235..098655ca02 100644 --- a/lib/classes/module/report/sqlquestion.class.php +++ b/lib/classes/module/report/sqlquestion.class.php @@ -56,8 +56,9 @@ class module_report_sqlquestion extends module_report_sql implements module_repo $this->total_row = $stmt->rowCount(); $stmt->closeCursor(); - if ($this->enable_limit) + if ($this->enable_limit) { $this->sql .= $this->filter->getLimitFilter() ? : ''; + } } else { $this->sql = " SELECT