cancel
Showing results for 
Search instead for 
Did you mean: 

Importing WSDL in External Definition

former_member200339
Participant
0 Kudos

Dear All,

A WSDL is created from a Function Module in the R/3 but when I try to import it, shows invalid WSDL. The reason is malformed XML. I found that the error is in the first line - <?xml version="1.0" encoding="utf-8"?>. When I modified it to <?xml version="1.0" ?>, the XML tag error is removed and it is now well formed.

But when I again try to import the wsdl file in the PI, I am getting following error - Element "Policy" is not permitted.

It seems there are extra characters in the header. The header is as follows:

<?xml version="1.0" encoding="utf-8"?><wsdl:definitions targetNamespace="urn:sap-com:document:sap:rfc:functions" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsoap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="urn:sap-com:document:sap:rfc:functions" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">

Can you tell me how to remove the extra characters?

Thanks and Regards.

Rana Brata De

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Rana Da

Is there any reason for importing the function module as WSDL ?

The easy and convenient way is to make the function module as remote enabled and then import it as RFC in ESR imported objects section.

markangelo_dihiansan
Active Contributor
0 Kudos

Adding to that, once you have imported it. Open the RFC and go to the WSDL tab, export it and you can import it as an external definition.

Regards,

Mark

Answers (3)

Answers (3)

former_member200339
Participant
0 Kudos

Dear All,

I have found a few details which I want to share with you all. Whenever we generate a WSDL from an RFC Module in the R/3, then the WSDL always throw error while importing in the PI External Definition. The reason is the presence of some elements in the generated WSDL which PI cannot recognize.

1. XML Format Error - the generated WSDL has <?xml version="1.0" encoding="utf-8"?> in the first line and the format error can be rectified if you remove - encoding="utf-8" from the first line.

2. WSDL Error - the generated WSDL has a segment <wsp:Policy> ... </wsp:Policy>. If you remove this segment then the WSDL will be imported successfully.

Thanks and Regards,

Rana Brata De

Former Member
0 Kudos

Hi Rana da,

Please refer the below thread. It might answer your question

http://scn.sap.com/thread/1884937

Regards

Bikash

Former Member
0 Kudos

Hi Rana,

These are the screenshots just to import the RFC and the you can see the WSDL as the other mates have said.

Regards.