Re: QuerySet without result_cache?

2009-08-28 Thread Sam Tregar
On Thu, Aug 27, 2009 at 8:18 PM, Alex Gaynor wrote: > > On Thu, Aug 27, 2009 at 5:56 PM, Sam Tregar wrote: > > On Thu, Aug 27, 2009 at 5:47 PM, Alex Gaynor > wrote: > >> > >> Instead of iterating over the QuerySet itself, use > >>

Re: QuerySet without result_cache?

2009-08-27 Thread Alex Gaynor
On Thu, Aug 27, 2009 at 5:56 PM, Sam Tregar wrote: > On Thu, Aug 27, 2009 at 5:47 PM, Alex Gaynor wrote: >> >> Instead of iterating over the QuerySet itself, use >> QuerySet.iterator(), this will avoid populating the result cache. > > Thanks, works great! 

Re: QuerySet without result_cache?

2009-08-27 Thread Sam Tregar
On Thu, Aug 27, 2009 at 5:47 PM, Alex Gaynor wrote: > > Instead of iterating over the QuerySet itself, use > QuerySet.iterator(), this will avoid populating the result cache. > Thanks, works great! This would make a good addition to the manual section that describes how

Re: QuerySet without result_cache?

2009-08-27 Thread Alex Gaynor
On Thu, Aug 27, 2009 at 5:34 PM, Sam Tregar wrote: > Hey all.  So, I figured out how to run my QuerySet through MySQLdb's > SSCursor!  Woo! > > Bad news: it's still using a ton of memory.  As far as I can tell it's being > used by QuerySet's internal _result_cache which is

QuerySet without result_cache?

2009-08-27 Thread Sam Tregar
Hey all. So, I figured out how to run my QuerySet through MySQLdb's SSCursor! Woo! Bad news: it's still using a ton of memory. As far as I can tell it's being used by QuerySet's internal _result_cache which is holding all the rows retrieved by the query. Is there any way to turn this cache