1. A method, comprising a database server registering a XML schema, wherein registering the XML schema includes: traversing a declaration of a first element that comprises a second element; while traversing said declaration of said first element: tracking on a stack a declaration of an element or a type encountered during said traversing; encountering said second element; and determining that said second element belongs to a type within a hierarchy of inheritance of a certain type of said first element by at least determining that said first element is on the stack; and in response to determining that said second element belongs to a type within a hierarchy of inheritance of a certain type of the first element, performing: determining that said XML schema defines a cyclic construct; determining a database representation capable of storing instances of said XML schema that contain said cyclic construct; and generating a mapping between constructs of said XML schema and said database representation.
1. A method, comprising a database server registering a XML schema, wherein registering the XML schema includes: traversing a declaration of a first element that comprises a second element; while traversing said declaration of said first element: tracking on a stack a declaration of an element or a type encountered during said traversing; encountering said second element; and determining that said second element belongs to a type within a hierarchy of inheritance of a certain type of said first element by at least determining that said first element is on the stack; and in response to determining that said second element belongs to a type within a hierarchy of inheritance of a certain type of the first element, performing: determining that said XML schema defines a cyclic construct; determining a database representation capable of storing instances of said XML schema that contain said cyclic construct; and generating a mapping between constructs of said XML schema and said database representation. 7. The method of claim 1 , wherein the first element and the second element are of a same type.