Thursday, 22 August 2013

Multivalued hierarchal xml tag

Multivalued hierarchal xml tag

I have a piece of text with many classifications and I'm thinking of a
perfect design for classification xml tag.
so for example, text id="1"has 2 classifications, each in tree structure:
class1
class2
class3
another classification:
class1
class6
class10
First xml design:
<class tree="class1;class2;class3"\>
<class tree="class1;class6;class10"\>
<text id="1">
here the text
</text>
Another design is
<class1>
<class2>
<class3>
</class3>
</class2>
</class1>
<class1>
<class6>
<class10>
</class10>
</class6>
</class1>
<text id="1">
here the text
</text>
Which one do you think is appropriate?, I want to be able to retrieve all
text belong to one class.
Any suggestions are welcome..

No comments:

Post a Comment