Based on schema logic, and at first blush, I think your second assertion 
is correct. A schema specifies what specific elements must contain, but 
not which elements must contain THEM. In other words, the schema 
validator looks down the tree, but not up or across the tree.

As a quick and dirty test, I created the following schema in oXygen:

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="">
<xs:element name="root">
            <xs:element ref="child" minOccurs="1"/>
            <xs:element ref="child2" minOccurs="1"/>
<xs:element name="child"/>
<xs:element name="child2"/>

Then, I created the following instance document:

<?xml version="1.0" encoding="UTF-8"?>
<child xmlns:xsi=""

Though the "root" element of my instance document (<child>) is defined 
as a required child element of <root>, there are no "down-tree" 
requirements for <child>. Thus, the document is valid with only <child>.

Bear in mind that this experiment was based on only the simplest of 
examples. Is there something I'm missing? I look forward to other 

Hope this has helped,

Jonathan Rochkind wrote:
> Anyone familiar with XML schemas (.xsd)?
> Can you help me figure something out. Is there something in the schema 
> that specifies what elements can serve as the 'root node'... or is any 
> element described in the schema avaialable for use as a 'root node', 
> and it'll still validate?
> Thanks for any tips.
> Jonathan

Casey A. Mullin
Discovery Metadata Librarian
Metadata Development Unit
Stanford University Libraries
[log in to unmask]