Nice. And the tests pass. So it looks like this now: def _col_aggregate(self, col, func): """executes func() function against the given column""" s1 = sql.select([col], self._clause, **self._ops).alias('u') return sql.select([func(s1.corresponding_column(col))]).scalar()
def min(self, col): """executes the SQL min() function against the given column""" return self._col_aggregate(col, sql.func.min) def max(self, col) ... See anything wrong with this or some disadvantage compared to the current SelectResults code? Randall Michael Bayer wrote: > you should use this to get at the column: > > col = s1.corresponding_column(col) > > of course trac is down so nothing is happening too soon at the moment. > > On Jul 21, 2006, at 4:15 PM, Randall Smith wrote: > > >>Attached is a proposed patch. >> >>Randall ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Sqlalchemy-users mailing list Sqlalchemy-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sqlalchemy-users