cancel
Showing results for 
Search instead for 
Did you mean: 

XML generation error

Former Member
0 Kudos

Hi All,

We are using using the services available in the ES bundles. In this situation, my structure for the proxy(a response(deep) structure) is a copy of the standard structure. Here the ABAP type is matched to the XSD: type.

The problem is when we try to generate an XML for this, no XML structure appears.

There's another proxy where in this doesnot happen. We are thinking it could be cos of the data type mismatch i.e char(10) is matched with XSD:token(since tehre are a lot of warning messages) but it works fine for the standard proxy even with the warnings.

Kindly help.

Regards,

Herwin Dsouza.

Accepted Solutions (0)

Answers (2)

Answers (2)

stefan_grube
Active Contributor
0 Kudos

> The problem is when we try to generate an XML for this, no XML structure appears.

I do not understand, what you mean by this. How do you create the XML and where do you verify, if it is available?

Former Member
0 Kudos

First a proxy is createdin SPROXY, in which there are some methods which populate the structure and then internally the XML is generated for that data. Now even if donot populate the data it should atleast display the XML structure( with tags and all) properly. This i am checking in transaction SXMB_MONI.

But the XML structure is not generated.

stefan_grube
Active Contributor
0 Kudos

So you see an entry in MONI without payload, or you see no message at all?

Do you catch exceptions from the proxy code and display them? Are there any exceptions?

Former Member
0 Kudos

This is how the payload appears

<?xml version="1.0" encoding="utf-8" ?> 
  <n0:AdvertisingSalesOrderERPByIDResponse_sync xmlns:n0="urn:infosys.com:infosys_salesorder:ordrmgmnt:socreate:100" xmlns:prx="urn:sap.com:proxy:DM1:/1SAI/TASE9FB9E0FA63A9F688A78:701:2008/06/06" />

stefan_grube
Active Contributor
0 Kudos

It seems that you have not filled the output structure correctly for calling the proxy method.

This has nothing to do with xsd:token, as I noticed that the corresponding ABAP type is "string", so you can assign a char(10) field to it.

Former Member
0 Kudos

even without filling the data... atleast the struture should appear right. Because thats happenin for another proxy...

<?xml version="1.0" encoding="utf-8" ?> 
- <n0:CreatePO xmlns:n0="urn:infosys.com:sap_ecc:ordermanagement:creditcard:100" xmlns:prx="urn:sap.com:proxy:DM1:/1SAI/TASC659492AA7761791885C:701:2008/06/06">
  <PONum /> 
  <PODate /> 
  <POType /> 
  <POGrp /> 

Also, the error that appears

HTTP response contains status code 401 with the description Unauthorized

stefan_grube
Active Contributor
0 Kudos

> even without filling the data... atleast the struture should appear right. Because thats happenin for another proxy...

This depends how you have maintained extended XML hanlding:

http://help.sap.com/saphelp_nwpi71/helpdata/EN/73/3f5c3c3906b006e10000000a11402f/frameset.htm

Per fault, empty values are ignored.

>

HTTP response contains status code 401 with the description Unauthorized

Maybe you try to fix this issue first.

Former Member
0 Kudos

For the successfully generated XML also these HTTP response errors are occuring. So there should be somether issue:(

stefan_grube
Active Contributor
0 Kudos

> So there should be somether issue

Maybe, but I cannot help you without debugging through your ABAP.

Sorry.

stefan_grube
Active Contributor
0 Kudos

When you copy an interface from standard and generate a proxy for this, it might happen that the structures are slightly different. So you might adapt your ABAP code according to this.

>We are thinking it could be cos of the data type mismatch i.e char(10) is matched with XSD:token

Check the generated ABAP structure for the requested data type.

Former Member
0 Kudos

Hi Stefan,

We have checked the ABAP structure. Actually everything is axactly as it is in the standard structure.