471,123 Members | 869 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,123 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 2889

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 discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by hooomee | last post: by
reply views Thread by Ganesh Muthuvelu | last post: by
3 posts views Thread by Sebastian Stein | last post: by
3 posts views Thread by foolproofplan | last post: by

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.