[jdom-interest] (no subject)
Vijay Mummaneni
mvbabu at hotmail.com
Thu Oct 24 10:34:08 PDT 2002
Hi,
I have an xml file that has 100 "Employee" elements. The elements are
related (they are from the RDBMS table). Each element is related to another
elemnt by employee-manager relationship. Currently it is flat xml file. What
I meant is, it looks like (I used JDOM to grab the data from the database) :
<Employees>
<employee id="1" name="emp1" managerId="2" />
<employee id="2" name="emp2" managerId="5" />
<employee id="3" name="emp3" managerId="5" />
<employee id="4" name="emp4" managerId="2" />
<employee id="5" name="emp5" managerId="null" />
</Employees>
Here is how I want to transform it :
<Employees>
<employee id="5" name="emp5" >
<employee id="2" name="emp2">
<employee id="4" name="emp4" />
<employee id="1" name="emp1" />
</employee2>
<employee id="3" name="emp3" />
</employee5>
</Employees>
Can you pl suggest me a solution, for this transformation. Is JDOM helpful
for the transormation ?
Thanks
vijay
_________________________________________________________________
Surf the Web without missing calls! Get MSN Broadband.
http://resourcecenter.msn.com/access/plans/freeactivation.asp
More information about the jdom-interest
mailing list