Altova Mailing List Archives>Archive Index >xmlschema-dev Archive Home >Recent entries >Thread Prev - Self reference in XML schema? [Thread Next] Re: Self reference in XML schema?To: Yang Feng <yfeng@-----.---> Date: 1/12/2005 11:59:00 AM Hi, Have a look at the personal.xsd/personal-schema.xml samples from Xerces J. http://cvs.apache.org/viewcvs.cgi/xml-xerces/java/data/ http://cvs.apache.org/viewcvs.cgi/xml-xerces/java/data/personal.xsd?view=markup http://cvs.apache.org/viewcvs.cgi/*checkout*/xml-xerces/java/data/personal-schema.xml?content-type=text%2Fplain Best Regards, George --------------------------------------------------------------------- George Cristian Bina <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger www.---.com Yang Feng wrote: > Hi there, > > > > I am new to XML schema. I wonder if I can use self reference in XML > schema. In my XML data, the EMPLOYEE element contains MANAGER element. > MANAGER is also an EMPLOYEE. How can I use XML schema to define this > relationship without repeating the same code for EMPLOYEE and MANAGER > elements? > > Is there any sample code? The XML have the following structure: > > > > <EMPLOYEE> > > <ID /> > > <name /> > > <MANAGER> > > <ID /> > > <name /> > > </MANAGER> > > </EMPLOYEE> > > > > Thanks in advance. > > > > Yolande > From David.Hirtle@n... Wed Jan 12 20:15:21 2005 Received: from bart.w3.org | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
