OT: how to convert XML data into db fields?

Bob Sneidar bobs at twft.com
Tue Jul 17 11:57:21 EDT 2012


I think you have to develop the logic yourself. XML is not a strict standard, so there is no unique method for conversion, at least to my knowledge. 

Bob


On Jul 17, 2012, at 2:50 AM, Tiemo Hollmann TB wrote:

> Hi it's a logical/design question,
> 
> I want to read a given XML format into a field based ("db like") LC
> application. My question is how you create the assignment between XML-Tags
> and LC fields.
> 
> Most of the XML-Tags are unique, like <productname>, or the parent nodes
> make them unique. Here I can easily create a relation table between the Tags
> and the fields. On the other hand there are some common Tags, which appear
> multiple times, like <textCode> together with  <text>.  Here the content of
> the first tag <textcode> (01,02,03) defines the db field for <textcode> and
> the following <text>. E.G. XML <text> content of <textcode> 01 is the "Main
> description", 02 is "Short description". For the assignment of these tags I
> could create a table for the relation between the content and the fields.
> The two completely opposite approaches in one processing needs a lot of hard
> coding where what to do to find the right db field.
> 
> 
> 
> Is this the way to process these kind of XML data or am I on the wrong lane
> and I don't see the obvious?
> 
> Any insights of XML pros appreciated
> 
> Tiemo
> 
> 
> 
> 
> 
> 
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list