I see you've had success with elementtree, but in case you are still
thinking about SAX, here is an approach that might interest you. The
idea is basically to turn your program inside-out by writing a
standalone function to process one myID node. This function has nothing
to do with SAX or parsing
Stefan Behnel wrote:
> [EMAIL PROTECTED] wrote:
> > I have an XML file which contains entries of the form:
> >
> >
> > 1
> > 2
> >
> > 1
> >
Thanks to everybody for the pointers. ElementTree is what I ended up
using and my looks like this (based on the ElementTree tutorial code):
[EMAIL PROTECTED] wrote:
> I have an XML file which contains entries of the form:
>
>
> 1
> 2
>
> 1
>
>
> Currently, I have written a SAX based handler that will read in all the
> entries and return a list of the contents of these
> entries. However this is not scalable and for my
[EMAIL PROTECTED] wrote:
> Hi, I have an XML file which contains entries of the form:
>
>
> 1
> 2
>
> 1
>
>
> Currently, I have written a SAX based handler that will read in all the
> entries and return a list of the contents of these
> entries. However this is not scalable and fo
Hi, I have an XML file which contains entries of the form:
1
2
1
Currently, I have written a SAX based handler that will read in all the
entries and return a list of the contents of these
entries. However this is not scalable and for my purposes it would be
better if I could iterat