From 7252ccd7c988d2fe2f218401a0a81738e19fa239 Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Sun, 27 Aug 2006 21:22:28 +0000 Subject: - fix to using query.count() with distinct, **kwargs with SelectResults count() [ticket:287] --- lib/sqlalchemy/ext/selectresults.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/sqlalchemy/ext/selectresults.py') diff --git a/lib/sqlalchemy/ext/selectresults.py b/lib/sqlalchemy/ext/selectresults.py index 79d56ec67..a35cdfa7e 100644 --- a/lib/sqlalchemy/ext/selectresults.py +++ b/lib/sqlalchemy/ext/selectresults.py @@ -28,7 +28,7 @@ class SelectResults(object): def count(self): """executes the SQL count() function against the SelectResults criterion.""" - return self._query.count(self._clause) + return self._query.count(self._clause, **self._ops) def _col_aggregate(self, col, func): """executes func() function against the given column -- cgit v1.2.1