[triangle-zpug] Re: Batching results from AdvancedQuery

David Handy david at handysoftware.com
Wed Aug 9 15:23:20 CEST 2006


You can also do:

    list(results)

to turn it into a list.

On Wed, Aug 09, 2006 at 09:06:30AM -0400, Geoff Davis wrote:
> (You don't need the 1 == 1; [r for r in results] works just fine.)
> 
> On Wed, 2006-08-09 at 09:04 -0400, Mike Revoir wrote:
> > For completeness, I got around this by creating a new list from the results.
> > 
> > results = [r for r in results if 1 == 1]
> > 
> > Mike
> > 
> > On 8/9/06, Mike Revoir <mrevoir at gmail.com> wrote:
> > > Hello all,
> > >
> > > I'm using AdvancedQuery to return catalog results so that I can sort on two
> > > indexes. When batching the results, I'm getting a StopIteration exception
> > > when navigating to the last page. Has anyone else experienced this? Any
> > > ideas on how to troubleshoot?
> > >
> > > Thanks,
> > >
> > > Mike
> > >
> > 
> > _______________________________________________
> > triangle-zpug mailing list
> > triangle-zpug at starship.python.net
> > http://starship.python.net/mailman/listinfo/triangle-zpug
> > 
> 
> 
> _______________________________________________
> triangle-zpug mailing list
> triangle-zpug at starship.python.net
> http://starship.python.net/mailman/listinfo/triangle-zpug
> 

-- 
David Handy
Computer Programming is Fun!
Beginning Computer Programming with Python
http://www.handysoftware.com/cpif/



More information about the triangle-zpug mailing list