[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Help deciphering someone else's XML schema

Subject: RE: Help deciphering someone else's XML schema
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Tue, 4 Apr 2006 23:28:45 +0100
RE:  Help deciphering someone else's XML schema
> I'm looking at some XSLT and XSD code from another company. 

The fact that you have some XSLT code doesn't make this an XSLT question or
make it on-topic for this list... 
> 
> <rr:CReport xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:rr="urn:Correlagen:RightReport"
> xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet"
> xsi:schemaLocation="urn:Correlagen:RightReport">
> 
> I'm a little rusty (well, very rusty) with the XML, XSD and 
> XSLT namespaces,
> and could use a little help deciphering that line.

This start tag contains three namespace declarations. The "rr" namespace is
needed because it's used in the element name. The "xsi" namespace is needed
because it's used in the attribute name. The "ss" namespace isn't obviously
needed on this start tag, but it's probably used somewhere deeper in the
content, judging from the fact that there's an "ss:Type" mentioned later on.

xsi:schemaLocation tells the system where to find a schema. In this case,
however, it's incorrect. It's supposed to contain a pair of URIs: first a
namespace URI (urn:Correlagen:RightReport) and then a location URI that says
where the schema for that namespace is to be found. The location URI is
missing, which is an error. You should raise this with the document
originator. 
> 
> When I take that file and put it into EditiX, and create a 
> Schema (.xsd)
> file, I get some errors with validation.

If you asked EditiX to create a schema, then I would expect it to create a
schema that the instance is valid against. You seem to be suggesting that it
has created a schema which defines the ss:Type attribute to be an xs:NCName,
when actually there's an ss:Type attribute that isn't an xs:NCName. Unless
I've read your post incorrectly, this would suggest a bug in the EditiX
schema generator, which you should report.

Michael Kay
http://www.saxonica.com/

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.