This week's book giveaway is in the Game Development forum.
We're giving away four copies of Badass: Making Users Awesome and have Kathy Sierra on-line!
See this thread for details.
The moose likes XML and Related Technologies and the fly likes need help in XSD. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Badass: Making Users Awesome this week in the Game Development forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "need help in XSD." Watch "need help in XSD." New topic

need help in XSD.

S. Nitesh
Ranch Hand

Joined: Jan 15, 2010
Posts: 36


I am a newbie in xsd.
I want to construct xsd for following xml format.

<b>some text<b/>
<c>some int<c/>
<d>some decimal<d/>

the main thing is that the xsd should allow <b>,<c> and <d> in any order with more than one occurrence of tag <d>.

thanks in advance.


Juraj Somorovsky

Joined: Feb 04, 2010
Posts: 1
Hi Nitesh,

There is the XSD schema:

The solution has one constraint: The <d> element cannot be used as a first element in <a>.
I don't know if it could be solved better, this is the best solution I've found.

However, I hope it will help you.

S. Nitesh
Ranch Hand

Joined: Jan 15, 2010
Posts: 36

Thanks Juraj.

It worked....
Thanks again.

I agree. Here's the link:
subject: need help in XSD.