On Thu, Jul 03, 2003 at 10:39:06AM -0700, Sukhwinder Singh wrote:
But I am not able to understand why I have to use two variables to access properties.
First uses student object returned by "for student in students" and the second uses o object returned by student.getObject().
As I said before, "students" in your example is a set of zcatalog results. Each result contains information about an object in the ZODB, but it is not that object. So for each result, you are de-referencing it to get the original object. Each catalog result object only knows about the metadata that the catalog is configured to index. Another solution would be to reconfigure the catalog to keep track of all the information you are interested in; this would make the extraction run faster, at the expense of taking more time to update this catalog. But since you are just extracting data from an application that will be retired, that is probably not worth the effort. -- Paul Winkler http://www.slinkp.com Look! Up in the sky! It's PREDOMINANT FORNICATOR! (random hero from isometric.spaceninja.com)