From 4cc7cbd0710487bcc3a78e34b2f5a11d0bc1fd70 Mon Sep 17 00:00:00 2001 From: "Michael J. Rubinsky" Date: Tue, 21 Dec 2010 16:08:47 -0500 Subject: [PATCH] actually *use* the sql limit clause --- content/lib/Tagger.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/content/lib/Tagger.php b/content/lib/Tagger.php index 1f6c5f436..58d7c3e86 100644 --- a/content/lib/Tagger.php +++ b/content/lib/Tagger.php @@ -526,7 +526,8 @@ class Content_Tagger $sql .= ' GROUP BY objects.object_name HAVING num_common_tags >= ' . $threshold . ' ORDER BY num_common_tags DESC'; - $this->_db->addLimitOffset($sql, array('limit' => $max_objects)); + $sql = $this->_db->addLimitOffset($sql, array('limit' => $max_objects)); + try { return $this->_db->selectAssoc($sql); } catch (Horde_Db_Exception $e) { -- 2.11.0