I want to define a smaple XML Schema for a social network website.I’ve defined a Person element and it’s related attributes and other child elements.it’s a part of the schema which I’ve defined. :
<xs:element name="Person" type="Person" />
<xs:complexType name="Person">
<xs:sequence>
<xs:element name="firstName" type="xs:string"/>
<xs:element name="lastName" type="xs:string"/>
<xs:element name="nickName" type="xs:string"/>
<xs:element name="age" >
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
<xs:maxInclusive value="120"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="birthDate" type="xs:date"/>
<xs:element name="gender" type="Gender" />
<xs:element name="contactDetails" type="ContactInfo"/>
<xs:element name="occupation" type="Occupation" />
</xs:sequence>
</xs:complexType>
now I want to define another child for Person as it’s friends but I dont know how can I do this.does any body have any Idea about this?
Does this work for you: