Another lxml.objectify question

Johann Spies johann.spies at gmail.com
Wed Feb 23 08:18:34 CET 2011


Stefan has  helped me in the past to make some progress on using
lxml.objectify.

I am trying to parse xml to create sql-compatible data.

My problem is that the xml records are not consistant: some might have tags
that does not appear in others.  That  makes it very difficult for me to
setup an exact dictionary.

Now my question: Is there a way that I can use the result of e.g. "a  =
record.item.descendantpaths()" to get a dictionary using a in this case be
the keys of a dictionary containing the full content of the record?

Regards
Johann

-- 
 May grace and peace be yours in abundance through the full knowledge of God
and of Jesus our Lord!  His divine power has given us everything we need for
life and godliness through the full knowledge of the one who called us by
his own glory and excellence.
                                                    2 Pet. 1:2b,3a
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20110223/aa00a09d/attachment.html>


More information about the Python-list mailing list