• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

logic problem using Dom Parser

 
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi,
i have a xml file which has a parent and child relationship maintainged. i have parsed that xml file using dom parser and retrieved the value in the tag and the value between the <> and </> tags in a LinkedList object.
to make it more clear i am giving the output of the xml file and the xml itself.
customer.xml
============

==========
the output i get
=====
[id, name]
[01, Suren]
[id, name]
[02, Wayne]
[orderId, title]
[123456, 10 PCs]
[orderId, title]
[123457, Hub]
[orderId, title]
[123458, 2 Laptops]
[ItemId, ProductName]
[100001, Dell Latitude Laptop,402.00]
[ItemId, ProductName, TotalPrice]
[100002, Packard Bell Desktop, 780.00]
[ItemId, ProductName, TotalPrice]
[100003, Hub Netgear,50.70]
[ItemId, ProductName, TotalPrice]
[100004, Dell Inspiron 8000,250.00]
=========
the problem is need to arrange the output in order in which the xml file is displaying.
Any help would be appreciated.
Regards
Kiranmanohar
 
Chicken Farmer ()
Posts: 1932
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Kiran! See that little piece of paper and pencil at the top of your post? You can use that to edit your post. That way, you don't have to make duplicate postings just to format stuff
(post with unformatted XML was deleted)
 
kiran manohar
Ranch Hand
Posts: 49
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi all,
I can't get u jason, is anyone there to help me in the above logic.
I want that very urgently.
thanks
kiran
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic