cancel
Showing results for 
Search instead for 
Did you mean: 

XSL Debugging.

Former Member
0 Kudos

Hi Experts,

I am using the standard component of IR , Store Connnectivity. There The standard Interface mapping that I am using is GMTLog2POSDM. File 2 RFC scenerio.

It contaiins 2 XSL mapping and 1 graphical mapping.

In sxmb_moni I am getting error : Exception occurred during XSLT mapping of the application, meaning that the data send from file to RFC scenerio do not match with the standard mapping.

Unlike Graphical mapping where I could pick the load from sxmb_moni and put it in messege mapping , and dry test it and find out which perticular field was giving error, here in this case, i cant make out which pericular field data is not matching in the XSL mapping.

Can u suggest any way, by which i canfind out where in the standard XSL mapping is the load failing.

Regards,

Arnab

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

I think the problem mainly occur in the part of the xsl where we specify the namespace.

It will be better if you can provide the xsl mapping

Thanks,

Tiny

Former Member
0 Kudos

Tiny,

can you pls tell me more, I didnt get ur reply. I am using standard components.

Regards,

Arnab.

PS. I need some way where i can put the load and debug/ test it to find where exactly in the code, it is giving error!

prateek
Active Contributor
0 Kudos

Have you tried using the payload from the test tab of Interface Mapping?

The other way of course would be loading the message type XSDs and XSL files in some external tools like Altova or XMLSpy.

Regards,

Prateek

Former Member
0 Kudos

Pratik,

Have you tried using the payload from the test tab of Interface Mapping?

Ya,, but here again, as i hav said there are 2 XSL mappings and 1 java maping.... Hw do I diversify from these 3 mappings amd chexck individually???

Altova / XML spy,, well I will try on it.

Vishnu,

ya,, that ios the last option,,,, but i was wondering for som simpler sol.

Srinivasrao

as per my knowledge you go to SXMB_Moni and go to TRACE error in the message u can find the exception

In SXMB_MONI, in trace, I see a BIG error.....startin with

<Trace level="1" type="T">TransfromerException during XSLT processing:</Trace>

<Trace level="1" type="T">javax.xml.transform.TransformerException: java.lang.ArrayIndexOutOfBoundsException at com.sap.engine.lib.jaxp.TransformerImpl.transform(TransformerImpl.java:255) at com.sap.aii.ibrun.server.mapping.MappingTransformer.transform................................blah blah blah......

eally cant make out anythin from here.. if u can explain futher , I can put up the entire trace error.

Patrick,

There you see that there is a way of displaying errors and warnings.

To answer your question Briefly, within SAP xi the message mapping works with namespaces. (Like ns0:). When creating an XLS please first load the message(s) inside the Graphical mapper and view as XML. Ensure that your XSL represents the predefined XML namespace as also done in the Graphical Mapper.

If you need more info let me know.

Greets

well the load that I am having is very big,, really don know,, hw to do that...

When creating an XLS please first load the message(s) inside the Graphical mapper

.... ya, goin through ur links ..

Awaitin reply....

Arnab .

Former Member
0 Kudos

Hi

Using the XSLT dev envmt is the simplest option in terms of effort & accuracy..

all other ways from XI would speculative w.r.t debugging/ fixing. may be - you can find out the issue, based on some hints.. but to nail it down, its the only & rather easiest option.

and finally, even if you find an error & if you have to fix it, you need to use the regular XSLT tools/IDEs

Regards

Vishnu

Former Member
0 Kudos

Vishnu ,

Ok...I will do exactly as u hav said. I hav a software called OPEN XML EDITOR. Now i hav 2 things with me. 1 the SAP standard XSL code through which the Payload is failing. Secondly, the erranous payload. Now I can COPY paste the XSL code from IR abd paste it in XML editor,, byt how to simulate the XML PAYLOAD.

Regards,

Arnab

Former Member
0 Kudos

Hi

Your editor may not be helpful for what you are trying to do.

check

- with your team, if there is any standard IDEs for xslt dev, used

- try stylus studio, xml spy etc.

for ex. in Stylus, you can load both your source/ target XSDs, your XSLT map & also your Payload for testing.

the screens look like Graphical mapping of XI & all required features are available.

Regards

Vishnu

Answers (4)

Answers (4)

Former Member
0 Kudos

Arnab,

Every message in SAP xi works with namespaces. Xi is hierrachical based lookup structure gives you the problem that namespaces are required.

See the example below.

xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge" (NS0: most likely the initiated namespace for SAP Xi)

xmlns:ns1="urn:pack.testnameSpace"

<xsl:template match="/">

<ns1:CODE> (Target namespace is required here)

<xsl:value-of select="ns0:Messages/ns0:Message2/ns1:out/Response/ns1:CODE"/> (all the ns0 and ns1 namespaces are determined at senderside)

</ns1:CODE>

Ensure that in the XSL mapping the source and target namespaces are included, if not the message cannot be read.

If the source message dont have a namespace the mapping looks like this

<xsl:value-of select="Messages/Message2/out/Response/CODE"/>

This is something you indeed can test in XMLSpy or in any XML editor

GReets

Former Member
0 Kudos

Hi

when you use XSLT mapping, there should be a development environment where you have XSLT development tools/ studios & the initial XSLT maps are developed.

Export XSLT from XI & open that in any of such tools, (Stylus Studio, XML spy etc) & test with your payload. thats the easiest way to Debug, these have advanced features.

Regards

Vishnu

Former Member
0 Kudos

Dear Arnab ,

i am also using the same scenario and i have faced Similar kind of problems,

as per my knowledge you go to SXMB_Moni and go to TRACE error in the message u can find the exception and accordingly you can work on that directly and i dont think you should do debugging for Transaction Logs,

any inputs reply me

Srinivas

Former Member
0 Kudos

Arnab,

There is a way of tracing within the XSL see:

http://help.sap.com/saphelp_nw04/helpdata/en/55/7ef3003fc411d6b1f700508b5d5211/content.htm and

http://help.sap.com/saphelp_nw04/helpdata/en/8a/7672f7d7e444439fd7024f806221a4/content.htm

There you see that there is a way of displaying errors and warnings.

To answer your question Briefly, within SAP xi the message mapping works with namespaces. (Like ns0:). When creating an XLS please first load the message(s) inside the Graphical mapper and view as XML. Ensure that your XSL represents the predefined XML namespace as also done in the Graphical Mapper.

If you need more info let me know.

Greets