Can override add constraints?
Posted: Fri Aug 19, 2016 8:22 am
Hi,
i would like to add some new Elements on a document instance. Before the Transformation, the instance is valid to Schema A where the new Elements are not known. Afterwards it is valid to a Schema B which is similar to A, but the new Elements are known and required. To do so, i have designed Schema B as overriding Schema A. Both Schemata A an B are XSD Version 1.1.
Everything is fine unless i try to add new constraints by overriding the root element. Schema A defines some constraints like xs:key, xs:keyRef and xs:unique on the root element. I would like to add additional constraints like xs:key for the new Elements. But in the moment i try to override the root element, oxyen (saxon) complains about its duplicate contraints.
Is there a way to add constraints by overriding an element which already has constraints?
Sincerely,
Frank Steimke
i would like to add some new Elements on a document instance. Before the Transformation, the instance is valid to Schema A where the new Elements are not known. Afterwards it is valid to a Schema B which is similar to A, but the new Elements are known and required. To do so, i have designed Schema B as overriding Schema A. Both Schemata A an B are XSD Version 1.1.
Everything is fine unless i try to add new constraints by overriding the root element. Schema A defines some constraints like xs:key, xs:keyRef and xs:unique on the root element. I would like to add additional constraints like xs:key for the new Elements. But in the moment i try to override the root element, oxyen (saxon) complains about its duplicate contraints.
Is there a way to add constraints by overriding an element which already has constraints?
Sincerely,
Frank Steimke