On Aug 2, 11:34 am, Michael Bayer <mike...@zzzcomputing.com> wrote:

> values() should be using the least amount of memory of any approach - it only 
> buffers 10 rows in memory at a time, and doesn't deal with session or object 
> accounting at all so is also much more performant than all().  I dont know 
> what "all().values()" is or if that's a typo.    
> Session.query(Event).values(func.distinct(Event.source)) should emit a brief 
> "SELECT DISTINCT" query and whip through a single column for the result.

It wasn't a typo; it was silliness on my part. The iterator approach
is blazingly fast. Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalch...@googlegroups.com.
To unsubscribe from this group, send email to 
sqlalchemy+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en.

Reply via email to