Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » xsd location and import problem
xsd location and import problem [message #37001] Tue, 03 February 2004 02:21 Go to next message
Eclipse User
Originally posted by: cipher8000.yahoo.com

Hi Ed,

I recently upgraded to xsd 2.0, and started have few problems related to
schema location and imports:

Please find the attachment for foo.xsd. I have deployed my xsd files under
tomcat webapps ROOT/xsd folder and i refer them using this following URL:
http://localhost:7575/./xsd/foo.xsd

When i tried to validate this schema using xsd-standalone-test.bat, i get
the following:

c:>xsd-standalone-test.bat -validate http://localhost:7575/./xsd/foo.xsd
--> http://localhost:7575/./xsd/foo.xsd
Error: URI http://localhost:7575/./xsd/foo.xsd Line 1 Column 1
XSD: The element may not have duplicate name and target namespace
'http://www.foo.com/foo#foo'
Error: URI http://localhost:7575/./xsd/foo.xsd Line 1 Column 1
XSD: The element may not have duplicate name and target namespace
'http://www.foo.com/foo#fooBoo'
Error: URI http://localhost:7575/./xsd/foo.xsd Line 17 Column 4
XSD: The type may not have duplicate name and target namespace
'http://www.foo.com/foo#FooType'


But if i use without "." (http://localhost:7575/xsd/foo.xsd) , then i don't
get validation error..
c:>xsd-standalone-test.bat -validate http://localhost:7575/xsd/foo.xsd

Please find the attachment for foo.xsd and boo.xsd. i deployed these files
under tomcat's webapps/ROOT/xsd directory.

thanks in advance for your help.

-muruga



  • Attachment: foo.xsd
    (Size: 0.86KB, Downloaded 79 times)
  • Attachment: boo.xsd
    (Size: 0.87KB, Downloaded 89 times)
Re: xsd location and import problem [message #37180 is a reply to message #37001] Thu, 12 February 2004 14:29 Go to previous message
Eclipse User
Originally posted by: merks.ca.ibm.com

Muruga,

I'm not sure anything has changed in this regard. The URIConverter's normalize
method never has done "." or ".." removal so if you initial starting URI may be
of that form, it's best to make sure it's canonical before passing it to the
resource set or you will end up loading the same resource using slightly
different URIs.


Muruga Chinnananchi wrote:

> Hi Ed,
>
> I recently upgraded to xsd 2.0, and started have few problems related to
> schema location and imports:
>
> Please find the attachment for foo.xsd. I have deployed my xsd files under
> tomcat webapps ROOT/xsd folder and i refer them using this following URL:
> http://localhost:7575/./xsd/foo.xsd
>
> When i tried to validate this schema using xsd-standalone-test.bat, i get
> the following:
>
> c:>xsd-standalone-test.bat -validate http://localhost:7575/./xsd/foo.xsd
> --> http://localhost:7575/./xsd/foo.xsd
> Error: URI http://localhost:7575/./xsd/foo.xsd Line 1 Column 1
> XSD: The element may not have duplicate name and target namespace
> 'http://www.foo.com/foo#foo'
> Error: URI http://localhost:7575/./xsd/foo.xsd Line 1 Column 1
> XSD: The element may not have duplicate name and target namespace
> 'http://www.foo.com/foo#fooBoo'
> Error: URI http://localhost:7575/./xsd/foo.xsd Line 17 Column 4
> XSD: The type may not have duplicate name and target namespace
> 'http://www.foo.com/foo#FooType'
>
> But if i use without "." (http://localhost:7575/xsd/foo.xsd) , then i don't
> get validation error..
> c:>xsd-standalone-test.bat -validate http://localhost:7575/xsd/foo.xsd
>
> Please find the attachment for foo.xsd and boo.xsd. i deployed these files
> under tomcat's webapps/ROOT/xsd directory.
>
> thanks in advance for your help.
>
> -muruga
>
> Name: foo.xsd
> foo.xsd Type: unspecified type (application/octet-stream)
> Encoding: x-uuencode
>
> Name: boo.xsd
> boo.xsd Type: unspecified type (application/octet-stream)
> Encoding: x-uuencode
Re: xsd location and import problem [message #583431 is a reply to message #37001] Thu, 12 February 2004 14:29 Go to previous message
Ed Merks is currently offline Ed Merks
Messages: 26047
Registered: July 2009
Senior Member
Muruga,

I'm not sure anything has changed in this regard. The URIConverter's normalize
method never has done "." or ".." removal so if you initial starting URI may be
of that form, it's best to make sure it's canonical before passing it to the
resource set or you will end up loading the same resource using slightly
different URIs.


Muruga Chinnananchi wrote:

> Hi Ed,
>
> I recently upgraded to xsd 2.0, and started have few problems related to
> schema location and imports:
>
> Please find the attachment for foo.xsd. I have deployed my xsd files under
> tomcat webapps ROOT/xsd folder and i refer them using this following URL:
> http://localhost:7575/./xsd/foo.xsd
>
> When i tried to validate this schema using xsd-standalone-test.bat, i get
> the following:
>
> c:>xsd-standalone-test.bat -validate http://localhost:7575/./xsd/foo.xsd
> --> http://localhost:7575/./xsd/foo.xsd
> Error: URI http://localhost:7575/./xsd/foo.xsd Line 1 Column 1
> XSD: The element may not have duplicate name and target namespace
> 'http://www.foo.com/foo#foo'
> Error: URI http://localhost:7575/./xsd/foo.xsd Line 1 Column 1
> XSD: The element may not have duplicate name and target namespace
> 'http://www.foo.com/foo#fooBoo'
> Error: URI http://localhost:7575/./xsd/foo.xsd Line 17 Column 4
> XSD: The type may not have duplicate name and target namespace
> 'http://www.foo.com/foo#FooType'
>
> But if i use without "." (http://localhost:7575/xsd/foo.xsd) , then i don't
> get validation error..
> c:>xsd-standalone-test.bat -validate http://localhost:7575/xsd/foo.xsd
>
> Please find the attachment for foo.xsd and boo.xsd. i deployed these files
> under tomcat's webapps/ROOT/xsd directory.
>
> thanks in advance for your help.
>
> -muruga
>
> Name: foo.xsd
> foo.xsd Type: unspecified type (application/octet-stream)
> Encoding: x-uuencode
>
> Name: boo.xsd
> boo.xsd Type: unspecified type (application/octet-stream)
> Encoding: x-uuencode
Previous Topic:How to provide a different schema content
Next Topic:Unresolved element when validate using DOM format
Goto Forum:
  


Current Time: Wed Sep 17 01:32:02 GMT 2014

Powered by FUDForum. Page generated in 0.02313 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software