473,385 Members | 1,615 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

maxOccurs setting with no minOccurs specified

If I have an <element name="test" maxOccurs="unbounded">
with no minOccurs attribute specified
does this mean I can have 0..unbounded occurences of <test>?
Or 1..unbounded occurences of test?

Thanks
Bruce
Nov 15 '07 #1
6 2978

br**********@my-deja.com <br**********@my-deja.comwrote in
<47**********************************@w28g2000hsf. googlegroups.com>:
If I have an <element name="test" maxOccurs="unbounded">
with no minOccurs attribute specified
does this mean I can have 0..unbounded occurences of
<test>? Or 1..unbounded occurences of test?
Read XML Schema Part 1: Structures 2E, 3.3.2.

--
....also, I submit that we all must honourably commit seppuku
right now rather than serve the Dark Side by producing the
HTML 5 spec.
Nov 15 '07 #2
br**********@my-deja.com wrote:
If I have an <element name="test" maxOccurs="unbounded">
with no minOccurs attribute specified
does this mean I can have 0..unbounded occurences of <test>?
Or 1..unbounded occurences of test?
The default for both minOccurs and maxOccurs is 1.

Conversely, attributes are optional by default!

HTH,

Pete Cordell
Codalogic
Visit http://www.codalogic.com/lmx/
for XML Schema to C++ data binding
Nov 15 '07 #3
Pavel Lepin wrote:
br**********@my-deja.com <br**********@my-deja.comwrote in
<47**********************************@w28g2000hsf. googlegroups.com>:
If I have an <element name="test" maxOccurs="unbounded">
with no minOccurs attribute specified
does this mean I can have 0..unbounded occurences of
<test>? Or 1..unbounded occurences of test?

Read XML Schema Part 1: Structures 2E, 3.3.2.
Or, if you value your sanity, you might want to buy a book! There are
some listed at:

http://amazon.com/s/ref=nb_ss_gw/103...schema&x=0&y=0

I personally get on well with Eric van der Vlist's XML Schema book
even though it doesn't rate too well on Amazon. It's got an appendix
at the back that's particularly good at answering this sort of
question.

I haven't read Priscilla's book. I keep meaning to buy a copy to see
whether it's worth recommending. She should know what she's talking
about though and has a lot of experience in XML schema in particular
and W3C in general.

Or, if you want a really basic introduction which aims to get you
started, but not teach you everything, there's my guide at:

http://www.codalogic.com/lmx/xsd-overview.html !!!

HTH,

Pete Cordell
Codalogic
Visit http://www.codalogic.com/lmx/
for XML Schema to C++ data binding

Nov 15 '07 #4

us****@tech-know-ware.com <us****@tech-know-ware.comwrote
in
<dc**********************************@v4g2000hsf.g ooglegroups.com>:
Pavel Lepin wrote:
>br**********@my-deja.com <br**********@my-deja.com>
wrote:
If I have an <element name="test"
maxOccurs="unbounded"with no minOccurs attribute
specified does this mean I can have 0..unbounded
occurences of <test>? Or 1..unbounded occurences of
test?

Read XML Schema Part 1: Structures 2E, 3.3.2.

Or, if you value your sanity...
I think I don't. I started to find a perverse pleasure in
trying to make any sense out of W3C recommendations. Sure,
it's mind-boggling. But the sheer sense of achievement in
it is priceless.
you might want to buy a book!
'Buy a book', they say. Well, maybe I would, but where the
heck is an electronic version, huh? Huh? I don't read stuff
printed on paper as a matter of principle these days.
Or, if you want a really basic introduction which aims to
get you started, but not teach you everything, there's my
guide at:

http://www.codalogic.com/lmx/xsd-overview.html !!!
Actually, the Original Old Authentic W3C Primer seems just
fine to me. A bit chewy, perhaps, but nothing a healthy
mind couldn't deal with.

--
....also, I submit that we all must honourably commit seppuku
right now rather than serve the Dark Side by producing the
HTML 5 spec.
Nov 15 '07 #5
On 15 Nov, 12:57, Pavel Lepin <p.le...@ctncorp.comwrote:
use...@tech-know-ware.com <use...@tech-know-ware.comwrote
in
<dc7f697f-293a-4bf5-82c4-f9963c086...@v4g2000hsf.googlegroups.com>:
Read XML Schema Part 1: Structures 2E, 3.3.2.
Or, if you value your sanity...

I think I don't. I started to find a perverse pleasure in
trying to make any sense out of W3C recommendations. Sure,
it's mind-boggling. But the sheer sense of achievement in
it is priceless.
I'm not sure whether to give you my respect, or my sympathy :-)
Or, if you want a really basic introduction which aims to
get you started, but not teach you everything, there's my
guide at:
http://www.codalogic.com/lmx/xsd-overview.html!!!

Actually, the Original Old Authentic W3C Primer seems just
fine to me. A bit chewy, perhaps, but nothing a healthy
mind couldn't deal with.
Yes, I meant to mention that in my original answer.

My view is that learning schema should be like climbing a mountain.
You go up one level, and then spend a while there acclimatizing.
Then, when your really comfortable with the principles you've learnt
go up another level and so on. Jumping straight into the Schema part
1 spec is a bit like going straight into the death zone. It'll
certainly give you a headache, and you might loose the will to live!

That's why I did my baby guide as a first step. I keep meaning to
write the next step! But then maybe schema part 0 is the next step.

My 2 cents!!!

Pete Cordell
Codalogic
Visit http://www.codalogic.com/lmx/
for XML Schema to C++ data binding
Nov 16 '07 #6

us****@tech-know-ware.com <us****@tech-know-ware.comwrote:
On 15 Nov, 12:57, Pavel Lepin <p.le...@ctncorp.comwrote:
>use...@tech-know-ware.com <use...@tech-know-ware.com>
wrote:
>Read XML Schema Part 1: Structures 2E, 3.3.2.
Or, if you value your sanity...

I think I don't. I started to find a perverse pleasure in
trying to make any sense out of W3C recommendations.
Sure, it's mind-boggling. But the sheer sense of
achievement in it is priceless.

I'm not sure whether to give you my respect, or my
sympathy :-)
Oh, sympathy. Sympathy for sure.
That's why I did my baby guide as a first step. I keep
meaning to write the next step!
I know the feeling. On the other hand, you went ahead and
wrote that guide...

--
....also, I submit that we all must honourably commit seppuku
right now rather than serve the Dark Side by producing the
HTML 5 spec.
Nov 19 '07 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: HQM | last post by:
If I create an element X of a primitive type with minOccurs=0 and nillable=true and run it through the WSDL generator I get a class with a property "X" of the primitive type plus a boolean...
0
by: Pete Beech | last post by:
Hi, I've looked all over for any information about this, and either this is a bug that I cannot find reported or I've misunderstood something. Lets say, in the XML Designer in VS.NET 2003, you...
0
by: Kurt | last post by:
Hi, (sorry if I'm cross posting - not quite sure where to put) I am basically trying to force the user of my web service to only send a valid dataset that is based on a schema I have created. ...
0
by: Robert Rae | last post by:
Does anyone know of a way to set minoccurs and maxoccurs from an attribute. An example would be: public string HelloWorld(DataInput dataInput) { return "Hello World"; } public class...
2
by: hooomee | last post by:
Given: <xs:choice maxOccurs=5> <xs:element name="Foo" type="bar" /> <xs:element name="Foo1" type="bar" /> <xs:element name="Foo2" type="bar" /> </xs:choice> Is the choice made once and then...
0
by: Ganesh Muthuvelu | last post by:
Hello, Please see the following schema: ********************** <?xml version="1.0" encoding="ISO-8859-1"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"...
3
by: Sebastian Stein | last post by:
Hi, I have the following XSD file (XML Schema 1.0): <xs:element maxOccurs="1" minOccurs="1" name="header"> <xs:complexType> <xs:sequence> <xs:element name="id" type="xs:positiveInteger"/>...
3
by: jlauman | last post by:
I'm getting an error on line 6 of the code shown below. The error is: Value 'unbounded' is not allowed for attribute 'maxOccurs' I'd appreciate any help in resolving this. Thanks, Jack ...
3
by: foolproofplan | last post by:
Maybe I am looking to far into a simple problem, but I am having quite a hard time figuring this out: I am currently trying to create a schema to represent an Element which contains other...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.