diff --git a/lib/Doctrine/ORM/Query.php b/lib/Doctrine/ORM/Query.php index c52a709db..02a1dc9eb 100644 --- a/lib/Doctrine/ORM/Query.php +++ b/lib/Doctrine/ORM/Query.php @@ -688,7 +688,8 @@ final class Query extends AbstractQuery ->getName(); return md5( - $this->getDql() . serialize($this->_hints) . $platform . + $this->getDql() . serialize($this->_hints) . + '&platform=' . $platform . ($this->_em->hasFilters() ? $this->_em->getFilters()->getHash() : '') . '&firstResult=' . $this->_firstResult . '&maxResult=' . $this->_maxResults . '&hydrationMode='.$this->_hydrationMode.'DOCTRINE_QUERY_CACHE_SALT'