Neil,

I checked the systemId that I construct the InputSource with and it's the
same for the repeated include and it still told me that it had duplicates.
Does it use the systemId is retrieve prior to calling the EntityResolver or
after?

Why do you think that this is a scenario that would only happen in a small
percentage of cases? We didn't really have a choice. We've got around 250
XSD files and a great deal of reusable types, so we had to come up large
directory structure and therefore we were forced to do these kind of
includes.

Thanks.
-Nathan

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 20, 2001 4:44 PM
To: [EMAIL PROTECTED]
Subject: RE: Schema error: sch-props-correct: Duplicate declaration for
a type ReadCodeType


Hi Nathan,

Try making sure that the systemId on the InputSource you return to the
parser is set the same in all cases.  This is what Xerces uses to try and
figure out whether the same schema is being included multiple times.

Bob's right; in principle I guess a parser could compute some kind of hash
on a document; but since everyone would have to take this performance hit,
not only the likely rather small percentage of folks who use includes in
this manner, I'm not sure it'd be worth it.

Cheers,
Neil

Neil Graham
XML Parser Development
IBM Toronto Lab
Phone:  905-413-3519, T/L 969-3519
E-mail:  [EMAIL PROTECTED]



"Beyer,Nathan" <[EMAIL PROTECTED]> on 09/20/2001 05:32:51 PM

Please respond to [EMAIL PROTECTED]

To:   "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
cc:
Subject:  RE: Schema error: sch-props-correct: Duplicate declaration for a
      type ReadCodeType


Funny you should mention that. I just downloaded the Quality Checker as
your
email arrived. I ran the schema through the quality checker and it said it
was fine, no error at all.

I did look at the schemas and check out the location statements and noticed
that they were different, but with my directory setup they have to be.
Here's what I have -
Schema B has this: <xsd:include
schemaLocation="../../../../foundation/code/ReadCodeLib.xsd"/>
Schema E and F have this: <xsd:include
schemaLocation="../../../foundation/code/ReadCodeLib.xsd"/>

As you can see they have a difference of one "../". Should this matter
though, since I'm doing customized entity resolution. I only have those
"../" so that XMLSpy can work, but in my EntityResolver I strip those of
and
resolve everything to a common root. If this does matter is there anyway to
work around this?


Thanks.

-----Original Message-----
From: Bob Schloss [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 20, 2001 4:07 PM
To: [EMAIL PROTECTED]
Subject: Re: Schema error: sch-props-correct: Duplicate declaration for
a type ReadCodeType



Nathan,

     Your structure looks okay.

     Although XMLSpy 4 may do the right thing (I don't know), I always
suggest that people do their checks with XSV and with IBM XML Schema
Quality Checker. For example, if the schemaLocation appears differently in
the different <include> element information items, even though you (a human
being) realize they all point to the same Web resource, Xerces and other
processors may not recognize this, so include them twice, therefore causing
a duplicate definition.  (I am one of the authors of IBM XML Schema Quality
Checker -- it can be downloaded from
http://www.alphaworks.ibm.com/tech/xmlsqc).

               Regards,
               Bob

Bob Schloss
IBM Thomas J. Watson Research Center
Yorktown Heights, New York, USA
http://www.research.ibm.com/XML



"Beyer,Nathan" <[EMAIL PROTECTED]> on 09/20/2001 04:49:35 PM

Please respond to [EMAIL PROTECTED]

To:   "Xerces-J-User (E-mail)" <[EMAIL PROTECTED]>
cc:
Subject:  Schema error: sch-props-correct: Duplicate declaration for a type
       ReadCodeType



I have some schemas that are producing a bunch of schemas that are
producing
these errors during schema validation on v1.4.3:
Schema error: sch-props-correct: Duplicate declaration for a type
ReadCodeType. ReadCodeType is the complexType that I've defined and is used
all over the place in my schemas.

My schemas utilize a number of include statements validate fine in XMLSpy
4.
Can anyone see anything wrong with this type of structure below:
Schema X includes A.
     Schema A includes B.
          Schema B includes Z.
     Schema A includes C.
          Schema C includes D.
               Schema D includes E.
                    Schema E includes Z.
               Schema D include F.
                    Schema F includes Z.

The complexType 'ReadCodeType' is in file Z. Why am I getting a schema
error
from this setup, it seems like a valid include structure. Note, if I remove
'Schema B includes Z' the schema is valid.

Any thoughts or ideas would be appreciated. Thanks.



CONFIDENTIALITY NOTICE

This message and any included attachments are from Cerner Corporation and are 
intended only for the addressee.  The information contained in this message is 
confidential and may constitute inside or non-public information under 
international, federal, or state securities laws and is intended only for the 
use of the addressee.  Unauthorized forwarding, printing, copying, 
distributing, or using such information is strictly prohibited and may be 
unlawful.  If you are not the addressee, please promptly delete this message 
and notify the sender of the delivery error by e-mail or you may call Cerner’s 
corporate offices in Kansas City, Missouri, U.S.A at (+1) (816) 221-1024.
------------------------------------------------------------------------

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to