[KLUG Members] Python XML to CSV

Adam Tauno Williams adam at morrison-ind.com
Mon Jan 30 16:09:54 EST 2006


Does anyone have an example for convering an XML document to a CSV, or
something similiar, in Python?

For instance, I want to turn -
<row><c01>2</c01><c02>22302101</c02><c03>022</c03><c04>00</c04><c05>01/25/2006</c05><c06>5</c06><c07/><c08/><c09>2.00</c09><c10>277202</c10><c11/><c12>277202 WHEEL,LOAD</c12><c13>65.03</c13><c14>130.06</c14><c15/><c16/><c17>Y</c17><c18>NPP40</c18><c19>2CL02277</c19><c20/><c21/><c22/><c23/><c24/></row>
-
into a 24 field CSV file (with a couple of caveats, but I think I can
figure those out).  I want to do it in Python as this example exists
inside BIE which has an internal Python-script action.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://www.kalamazoolinux.org/pipermail/members/attachments/20060130/2aad01a3/attachment.bin


More information about the Members mailing list