I am looking for a way to extract all information available in a xml file to a flat file or a database.
For example
<r>
<P>
<color val="1F497D"/>
</P>
<t val="123" val2="234">TEST REPORT</t>
</r>
I would want this as
r
P
color,val,1f497d
t,val,123
t,val2,234
Any pointers on how to go about this in python?
Install
lxmlthen:I’ll leave it up to you to format the output.