Altova Mailing List Archives>Archive Index >xmlschema-dev Archive Home >Recent entries >Thread Prev - RE: using types from an included file in a different namespace [Thread Next] Re: using types from an included file in a different namespaceTo: "Antoli, Leo" <Leo.Antoli@-----.--->, xmlschema-dev@--.--- Date: 10/28/2006 6:08:00 AM On 10-27-2006 12:36 PM, Antoli, Leo wrote: > Files attached. > > When I try to validate A.xml I get: > > In XMLSpy">XMLSpy: It's valid. > > In Saxon: > Error at xs:element on line 4 of file:/A.xsd: > Cannot reference schema components in namespace http://mynamespace2 as it > has not been imported Warning: One error was found while processing the > schema Warning: Validation will continue without the schema at A.xsd > Validation error on line 1 column 137 of file:.../A.xml: > Cannot validate <hello>: no element declaration available Validation of > source document failed > > In Stylus Studio (I think it uses Xerces-C): > file:.../A.xsd:4,46: Schema Representation Constraint: Namespace > 'http://mynamespace2' is referenced without <import> declaration > The XML document A.xml is NOT valid (1 errors) Stylus Studio does in fact uses Xerces-C; it pretty closely tracks the current Apache releases, so if you're on 2007 it should be 2.7.something or other. Included with it are XSV and (if you have the Enterprise release) Saxon, and several Microsoft implementations. So, if you get into a corner case where some allow it, some don't, and the rule has (as Mike Kay stated) some wiggle room, I'd decide based on this criteria: "Do I care about portability?" > Regards, > Leo. -- Sincerely, Tony Lavinio Stylus Studio Principal Software Architect www.---.com/ | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
