Elements substitutable for a head element are required to have types derived from the head element's type, but are not required to enforce the identity constraints of the head element.
In other words, the substitutable elements may not validate the same way as the head element. Beware!
Example: A BookStore consists of multiple Book elements and each Book element is uniquely identified by its ISBN. Here is an example BookStore:
<Title>Illusions The Adventures of a Reluctant Messiah</Title>
<Publisher>Dell Publishing Co.</Publisher>
<Title>The First and Last Freedom</Title>
<Publisher>Harper & Row</Publisher>
Note that each ISBN value is unique. We want the XML Schema to enforce that uniqueness.
A way to accomplish this is using xsd:key.
Let's look at the XML Schema code.
BookStore consists of an unbounded number of Book elements:
Oops! Notice that my client messed up, he mistakenly identified both books by the same ISBN value.
XML Schema validation of the document returns "valid".
My client has an error in his XML document and it is not being caught by schema validation.
Lesson Learned: element substitution is powerful. But without intimate knowledge of the head element, use of your substitution elements may result in XML documents with erroneous data that is not detected by schema validation.