Commit c3439aee authored by monolit's avatar monolit

Ticket #312

Duplicated params in sql when using LIMIT or OFFSET and MYSQL - due to Doctrine_Query::getQuery()
parent 44101abc
...@@ -824,7 +824,6 @@ class Doctrine_Query extends Doctrine_Hydrate implements Countable { ...@@ -824,7 +824,6 @@ class Doctrine_Query extends Doctrine_Hydrate implements Countable {
switch(strtolower($this->conn->getName())) { switch(strtolower($this->conn->getName())) {
case 'mysql': case 'mysql':
// mysql doesn't support LIMIT in subqueries // mysql doesn't support LIMIT in subqueries
$params = array_merge($this->params, $params);
$list = $this->conn->execute($subquery, $params)->fetchAll(PDO::FETCH_COLUMN); $list = $this->conn->execute($subquery, $params)->fetchAll(PDO::FETCH_COLUMN);
$subquery = implode(', ', $list); $subquery = implode(', ', $list);
break; break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment