[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Namespace issue
Looks like a bug in the schema generator. If you add abc: in type="abc:..." in these two lines > <xs:element name="array" type="arrayType"/> > <xs:element name="string" type="stringType"/> it shouldn't have the error any more. -W On 9 December 2010 12:05, Silent lights <silentlights@xxxxxxxxxxx> wrote: > Hello there, > I am trying to generate an XSD with an XML instance. For this XML Instance, > > <?xml version="1.0" encoding="UTF-8"?> > <abc:io xmlns:abc="urn:com.mycompany:bizatoms"> > <abc:array> > <abc:string>Data posted</abc:string> > </abc:array> > </abc:io> > > The generated Schema was > > <?xml version="1.0" encoding="utf8"?> > <?bpc.pltype.out bpm.pltype=xsd,bpm.pltype=xml?> > <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" > xmlns:abc="urn:com.mycompany:bizatoms" > targetNamespace="urn:com.mycompany:bizatoms" elementFormDefault="qualified" > attributeFormDefault="unqualified"> > <xs:element name="io"> > <xs:complexType> > <xs:sequence> > <xs:element name="array" type="arrayType"/> > </xs:sequence> > </xs:complexType> > </xs:element> > <xs:complexType name="arrayType"> > <xs:sequence> > <xs:element name="string" type="stringType"/> > </xs:sequence> > </xs:complexType> > <xs:simpleType name="stringType"> > <xs:restriction base="xs:string"/> > </xs:simpleType> > </xs:schema> > > I get an error while valididating the Schema : 'stringType' must refer to an > existing simple or complex type. > > I am not able to understand why this error pops up.. although the type is > defined and it is under the same namespace. > > Can someone highlight on this particular case, and suggest how would the schema > be "pre-fixed perhaps?" > > thank you > Densil
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|