Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > Re: make a unbroken sequence of id attribute with XSD

Reply
Thread Tools

Re: make a unbroken sequence of id attribute with XSD

 
 
eephyne
Guest
Posts: n/a
 
      03-23-2011
there will be no multiple occurence of a simple level , but since i will load the xml , it'll be nice if i had just to check it against the xsd to assure that there is no holes in the level (no missing level 5 per example) and not checking it inside the program .
 
Reply With Quote
 
 
 
 
Joe Kesselman
Guest
Posts: n/a
 
      03-24-2011
On 3/23/2011 1:32 PM, eephyne wrote:
> there will be no multiple occurence of a simple level , but since i
> will load the xml , it'll be nice if i had just to check it against
> the xsd to assure that there is no holes in the level (no missing
> level 5 per example) and not checking it inside the program .


Think of schemas as providing higher-level _syntax_ constraints. In most
cases, an application which wishes to impose semantic constraints such
as this one will have to do so itself. And that's entirely reasonable;
the range of possible semantic constraints is essentially unbounded. A
limit had to be set somewhere, and to prevent scope creep it was set at
the level of datatypes.

Of course if you have control of both the code generating the XML and
the code consuming the XML, you may not need to explicitly enforce the
semantic constraints at all.


--
Joe Kesselman,
http://www.love-song-productions.com...lam/index.html

{} ASCII Ribbon Campaign | "may'ron DaroQbe'chugh vaj bIrIQbej" --
/\ Stamp out HTML mail! | "Put down the squeezebox & nobody gets hurt."
 
Reply With Quote
 
 
 
 
Joe Kesselman
Guest
Posts: n/a
 
      03-24-2011
I'd also agree that, if you just want things numbered sequentially, it
would make more sense to compute the number from context rather than
inserting the number into the document. XPath/XSLT/XQuery will be glad
to find you the Nth sibling instance, for example.


--
Joe Kesselman,
http://www.love-song-productions.com...lam/index.html

{} ASCII Ribbon Campaign | "may'ron DaroQbe'chugh vaj bIrIQbej" --
/\ Stamp out HTML mail! | "Put down the squeezebox & nobody gets hurt."
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: make a unbroken sequence of id attribute with XSD eephyne XML 1 03-24-2011 09:32 AM
Re: make a unbroken sequence of id attribute with XSD eephyne XML 1 03-21-2011 08:48 PM
Re: make a unbroken sequence of id attribute with XSD eephyne XML 2 03-21-2011 09:14 AM
Re: make a unbroken sequence of id attribute with XSD eephyne XML 1 03-18-2011 05:36 PM
make a unbroken sequence of id attribute with XSD eephyne XML 2 03-18-2011 02:50 PM



Advertisments