Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8944

Re: parameter use in simple transformation

$
0
0

Indeed, it seems the only solution is to define it as a root. Is that a problem?

 

This code works:

  DATA xml_string TYPE string.
  CALL TRANSFORMATION ztest
        SOURCE  var_xmlns = 'urn:test'
        RESULT  XML  xml_string.

The transformation :

<?sap.transform simple?>
<tt:transform xmlns:tt="http://www.sap.com/transformation-templates">
<tt:root name="VAR_XMLNS"/>
<tt:template>
  <Jetstream>
   <tt:attribute name="xmlns" value-ref="VAR_XMLNS"/>
value
</Jetsream>
</tt:template>
</tt:transform>

The result (in xml_string) :

<?xml version="1.0" encoding="utf-16"?>
<Jetstream xmlns="urn:test">##  value##  </Jetstream>

Viewing all articles
Browse latest Browse all 8944

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>