On Nov 19, 11:03 am, Stefan Behnel <[EMAIL PROTECTED]> wrote:
>
> Use iterparse() instead of parsing the file into memory completely.
>
> *stuff*
>
> Stefan
That worked wonders. Thanks a lot, Stefan.
So, iterparse() uses an iterate -> parse method instead of parse() and
iter()'s parse -> iterate
Gibson wrote:
> I'm attempting to do the following:
> A) Read/scan/iterate/etc. through a semi-large XML file (about 135 mb)
> B) Grab specific fields and output to a tab-delimited text file
> [...]
> out = open('output.txt','w')
> cat = etree.parse('catalog.xml')
Use iterparse() instead of pa
I'm attempting to do the following:
A) Read/scan/iterate/etc. through a semi-large XML file (about 135 mb)
B) Grab specific fields and output to a tab-delimited text file
The only problem I'm having is that the tab-delimited text file
requires a different order of values than which appear in the X