[sqlalchemy] Returning an attribute from an object when using query_property()?

2010-08-02 Thread Zippy P
Hi all: I have the following code: class EventQuery(Query): def histogram(self): ''' return a histogram of source / count(source) given an eventquery'' ... ... class Event(Base): __tablename__ = 'events' query = Session.query_property(query_cls = EventQuery) name =

Re: [sqlalchemy] Returning an attribute from an object when using query_property()?

2010-08-02 Thread Michael Bayer
On Aug 2, 2010, at 12:41 PM, Zippy P wrote: Hi all: I have the following code: class EventQuery(Query): def histogram(self): ''' return a histogram of source / count(source) given an eventquery'' ... ... class Event(Base): __tablename__ = 'events' query =