Posted on 2006-05-12
Last Modified: 2013-11-19
Hi All,

I posted this in XML forum, but didn't got any reply.. but since it is related to Java also, so posting it here as well...

Please help!!!

I am very new to XML.. never done it, so kindly be patient..

I want to build a xml

where I have order
 in order there can be many allocations
 in allocation there can be many execution

also, order has price, quantity, clientId etc fields
allocation has price, quantity, account etc fields
exeuctions has price quantity, id etc fields

I want to do it the right way --- to build schema or dtd first and based on that create a xml

objective is that finally we will use this dtd/schema to automatically create XML using java ...

and then somehow based on XML-- build automatically the java objects  ---  like Order Object ..  Allocation Object etc..

I have all these objects in java already but rest of the stuff needs to be done..

Please help me create this...

again, sorry, I am very new to XML -- don't know much about basics of it.. so kindly be patient answering my basic questions...

Question by:shivani
    LVL 14

    Accepted Solution

    I also dont know much about xml. :-)
    here is a good place to start learning java's APIs for xml

    Processing XML with Java:
    LVL 30

    Assisted Solution

    You should create the XSD first. Take a sample XML if you want. For your case, it might be like:

      <Order ID = "....">
          <Allocation ID = "....">
            .... // other fields

    You will need to define an XSD containing data-types of all of these and constraints like how many times a node can occur, etc

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Live - One-on-One Java Help from Top Experts

    Solve your toughest problems, fast.
    Java experts are online now and ready to help you.

    Suggested Solutions

    Title # Comments Views Activity
    hash value 2 29
    commonTwo  challenge 63 68
    json example 39 77
    SP to delete duplicates 15 46
    Shoutout to Emily Plummer ( for giving me this article! She did most of it, I just finished it up and posted it for her :)    Introduction In a previous article (http://www.experts-exchang…
    Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
    The viewer will learn how to implement Singleton Design Pattern in Java.
    The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

    761 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now