Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XML
|
XML General XML discussions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XML section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 5th, 2006, 04:53 AM
Friend of Wrox
 
Join Date: Sep 2004
Posts: 103
Thanks: 0
Thanked 0 Times in 0 Posts
Default xsd deleme

Hi all,
In his book "System Architecture with XML", Berthord Daum lists some of the DTD deficiencies and thereafter introduces XML Scheme to resolve such issues. One of them is as follows:

Bags: DTDs cannot specify unordered sequences of elements (bags). For a given model group (e1,e2,e3) the elements e1 . . . e3 must appear in the document instance in the defined sequence. To simulate an unordered sequence, all possible permutations must be given as alternatives: ((e1,e2,e3) | (e1,e3,e2) | (e2,e1,e3) | . . . ).

Well it seems this is not resolved in xsd either:
   http://www.thescripts.com/forum/thread86178.html

Is it so ?!

 
Old July 5th, 2006, 05:17 AM
mhkay's Avatar
Wrox Author
 
Join Date: Apr 2004
Posts: 4,962
Thanks: 0
Thanked 292 Times in 287 Posts
Default

Yes, XML Schema has restrictions in this area too. They aren't precisely the same as the restrictions in DTDs, but fairly similar.

You can use xs:all to say "each one of the following elements may appear zero or one times [you can say which], in any order". You can also use xs:choice to say "each one of the following elements may appear any number of times in any order". What you can't do is to say "there can be up to three authors, up to two editors, and exactly one publisher, in any order".

Michael Kay
http://www.saxonica.com/
Author, XSLT Programmer's Reference and XPath 2.0 Programmer's Reference





Similar Threads
Thread Thread Starter Forum Replies Last Post
XSD.EXE Gen’d C# Deserializing w/ .xsd Subst Group greenstone XML 0 November 9th, 2007 09:27 PM
XSD JonDeNoitaly BOOK: Beginning Visual Basic 2005 Databases ISBN: 978-0-7645-8894-5 2 May 7th, 2007 08:32 AM
XSD with Namespacing davidjlowry XML 1 June 15th, 2006 04:09 AM
xsd question kgoldvas XML 3 May 4th, 2006 03:14 AM
Merging XSD files in one XSD file by using what? haoxuqian XML 1 November 4th, 2005 01:42 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.