From: Dieter Maurer <dieter@handshake.de> Date: 2002/12/20 Fri PM 01:58:27 EST To: mackay_d@bellsouth.net (David Mackay) CC: zope@zope.org Subject: Re: [Zope] Object propogation
David Mackay writes:
Do you have any suggestions as to how to preserve the list of mybrains objects so that I can access that, rather than re-executing the query? You cannot preserve the sequence of "mybrain" objects, but you can store their record ids and resolve the ids later into the objects by means of a catalog method.
For details, please read the "ZCatalog" section of
<http://www.dieter.handshake.de/pyprojects/zope/book/chap3.html>
It tells you the exact name of the record id and the name of the catalog method.
You are probably also interested in Pythons "list comprehension": [x.record_id_ for x in catalog(...)]
Dieter
Thanks, the way I was doing it was a bit inefficient.
PS: Please stay on the list.
Sorry, I just hit reply without looking. Dave