This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Error in WSDL  RSS feed

 
Bharat Makwana
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I am getting following error in my WSDL, Can any one tell me what is that error and how I can fix it.

s4s-elt-schema-ns: The namespace of element 'simpleContent' must be from the schema namespace, 'http://www.w3.org/2001/XMLSchema'.

Following is a excerpt from WSDL, ( I am getting error at line #1,#2,#3,#4)




Thank you
[ June 19, 2007: Message edited by: Bharat Makwana ]
 
Srivatsa Katta
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Bharat,

Since you have declared the XMLSchema namespace with the prefix 's'



you have to use fully qualified names for all the elements you are using from this namespace (all schema elements)

so change the schema to the following.



-Srivatsa Katta
 
Bharat Makwana
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Srivasta,

I have made changes as you suggested, But now I am geting following two errors

1) s4s-att-not-allowed: Attribute 'maxOccurs' cannot appear in element 'element'. at Line #1

2)src-ct.2.1: Complex Type Definition Representation Error for type '#AnonType_action'.
When <simpleContent> is used, the base type must be a complexType whose content type is
simple, or, only if restriction is specified, a complex type with mixed content and
emptiable particle, or, only if extension is specified, a simple type. 'string' satisfies
none of these conditions.
at line #4

 
Srivatsa Katta
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

1) s4s-att-not-allowed: Attribute 'maxOccurs' cannot appear in element 'element'. at Line #1


minOccurs and maxOccurs can not be used for the root elements, it can be used only by the child elements used in either sequence/all/any


2)src-ct.2.1: Complex Type Definition Representation Error for type '#AnonType_action'.
When <simpleContent> is used, the base type must be a complexType whose content type is
simple, or, only if restriction is specified, a complex type with mixed content and
emptiable particle, or, only if extension is specified, a simple type. 'string' satisfies
none of these conditions. at line #4


the wrong combination of schema elements are used for restricting the base string. use it like given below



I would suggest you to please go through the XSD primer before going to wsdl's it will give you the better understanding of schema.

-Srivatsa Katta
 
Bharat Makwana
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Srivasta, Now there is no errors.

Thank you very much for your replies.

I am getting this error in other wsdl can you help me with this please

The part 'messageIds' has an invalid value 'MessageIDs' defined for its type. Type declarations must refer to valid values defined in a schema.
------------> at line #1



Thank you
[ June 19, 2007: Message edited by: Bharat Makwana ]
 
Srivatsa Katta
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
add this attribute targetNamespace="http://service.ebms.edi.cecid.hku.hk/" in your schema element.



-Srivatsa Katta
 
Bharat Makwana
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you Srivasta.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!