Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - converting xml file to schema file problem [Thread Next] Re: converting xml file to schema file problemTo: NULL Date: 10/7/2009 1:35:00 PM sharan wrote: > i am converting a xml file having namespaces in to schema file (.xsd) > for validation. > > my xml file is > test.xml > ----------------------------------------------------------- > <?xml version="1.0" encoding="UTF-8"?> > <root xmlns:xs="http://www.w3.org/2001/XMLSchema" > xmlns:h="http://www.w3.org/TR/html4/" > xmlns:f="http://www.w3.org/TR/scxml/"> > <h:table> > <h:tr>vegitables</h:tr> > <h:td>Apples</h:td> > </h:table> > > <f:table> > <f:name>African Coffee Table</f:name> > <f:data>hari</f:data> > <f:length>oum</f:length> > </f:table> > </root> You will need three schemas, one for each namespace used (i.e. no namespace for the root element and two different namespaces for the other elements). Then the schema for the root element needs to import the other two schemas and reference the type or element definitions in those schemas. -- Martin Honnen http://msmvps.com/blogs/martin_honnen/ | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
