cancel
Showing results for 
Search instead for 
Did you mean: 

XSL Tranformation Action Block not working

0 Kudos

HI All,

We have recently moved from MII12.1 to 15.1.

Some of our interfaces involved XSL transformation on the XML files and for some reasons, the XML transformation action block is not working.

We are getting error like

  • [WARN] [XSL_Transformation_0]The result of XSLTransformation is not a valid XML

We tried different options of loading XML file, like creating a local XML variable and assigning that to InputXSL property, creating new file in web folder and assigning link to this file as input Transform Property but with no luck.

Same peace of code is working fine on MII 12.1, is this a bug in MII 15.1 or we are doing something wrong.

Thanks

Rupesh

Accepted Solutions (1)

Accepted Solutions (1)

former_member186805
Participant
0 Kudos

Hi Rupesh,


Please find attached screenshot of XSL Transformation i just developed using XSL and XML provided here in this link


http://www.w3schools.com/xsl/tryxslt.asp?xmlfile=cdcatalog&xsltfile=cdcatalog



This works perfect for me in 15.1 .


Few things to verify :


if you are using Transform URL : make sure it is valid , you can check by hitting it in IE


Input XSL in case if you have stylesheet ready ( you can try this if you have not done so) just like below

create xml variable and assign it stylesheet and again assign it it input xsl param of xsl transformation block same as for Input XML


You should get the output.

]

0 Kudos

Hello Ayush,

Thanks for your reply, this particular thing worked on our server.

However, our output from XSL action block is also XML. We have tried in all possible ways, like Loading XML from XML loader, or creating the XML as local variable but all results in same things.

Moreover, we created a transaction in 12.1 and imported that in 15.1, The transaction is working in 12.1 but not in 15.1. Not sure what the problem is.

I have attached our XSL and XML for your reference, let me know if you see any issue in that.

Thanks

Rupesh

former_member186805
Participant
0 Kudos

Hi Rupesh,

I am able to resolve the issue. Issue was in your XSLT File, some of the mentioned part was unrecognizable to the XSL Transformation logic which i found out from some of my XSLT tools.

Transform was having some issues

check below screenshots and find attached  modified XSL ( only removed the part which has been highlighted in below screenshot)

after that it worked successfully.

after that , transaction worked like charm

former_member186805
Participant
0 Kudos

valid output xml as attached below

I hope this is what you are looking for an output.

former_member186805
Participant
0 Kudos

Hi Rupesh,

After further analysis on the xslt file, i found the below statement in your XSLT

<xsl:namespace-alias result-prefix="" stylesheet-prefix="a"/>

"result-prefix" should not have empty VALUE .

it should have some value like below.

All you need to fill "xsl" in the "result-prefix" and it should work. And you NO NEED to remove anything from your xslt file

<xsl:namespace-alias stylesheet-prefix="a" result-prefix="xsl"/> 
0 Kudos

Too good Mate.

While this worked very well, I need to now figure out why this worked in 12.1 and not in 15.1.

It will take me enormous effort to change different XSL's at different Places, but that is my head ache and I think I will take this up with SAP.

I also noticed error in NW Logs as below so I think the issue is more deeper into MII or Netweaver core libraries.


D:\usr\sap\MD3\J00\j2ee\cluster\server0\dummy.xsl; Line #0; Column #0; The result-prefix attribute of an xsl:namespace-alias element has the value '', but there is no namespace declaration for the prefix '' in scope for the element.

Thanks Again.

Rupesh

former_member186805
Participant
0 Kudos

Hi Rupesh,

For this error, please refer my last reply on this thread, this error shall disappear.

Answers (0)