<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: XML space tag problem in XML simple transformation de-serialization in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658035#M1866912</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you so much for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 11 Nov 2014 07:18:25 GMT</pubDate>
    <dc:creator>Rajesh_Amirinen</dc:creator>
    <dc:date>2014-11-11T07:18:25Z</dc:date>
    <item>
      <title>XML space tag problem in XML simple transformation de-serialization</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658031#M1866908</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;Dear friends,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a problem while converting xml file into internal table (de-serialization) using simple transformation.&lt;/P&gt;&lt;P&gt;there is a tag like &amp;lt;tag&amp;gt; &amp;lt;/tag&amp;gt; and I am using condition to check whether tag consist data or not.&lt;/P&gt;&lt;P&gt;because of the space value in the tag I am getting an exception 'CX_ST_COND_CHECK_FAIL' during the condition check.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;before deserialization, i am removing empty tags from the xml by using below statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;REPLACE &lt;SPAN class="L0S52"&gt;ALL &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OCCURRENCES &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OF &lt;/SPAN&gt;REGEX &lt;SPAN class="L0S33"&gt;'&amp;lt;\w+/&amp;gt;' &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;IN &lt;/SPAN&gt;l_string &lt;SPAN class="L0S52"&gt;WITH &lt;/SPAN&gt;&lt;SPAN class="L0S33"&gt;''&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;but because the tag has the space value it is not getting removed from the XML.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;and i am using below code to check is there any tag with empty value. at this condition, because of space value&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;i am getting the exception&amp;nbsp; 'CX_ST_COND_CHECK_FAIL'.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;tt:cond check=&lt;SPAN class="L1S33"&gt;"DENIAL_CODE!=''"&amp;gt;&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;DenialCode tt:value-ref=&lt;SPAN class="L1S33"&gt;"DENIAL_CODE"&lt;/SPAN&gt;/&amp;gt;&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/tt:cond&amp;gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L1S33"&gt;please advise on this.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rajesh&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&lt;SPAN class="L0S55"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 01 Nov 2014 08:09:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658031#M1866908</guid>
      <dc:creator>Rajesh_Amirinen</dc:creator>
      <dc:date>2014-11-01T08:09:29Z</dc:date>
    </item>
    <item>
      <title>Re: XML space tag problem in XML simple transformation de-serialization</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658032#M1866909</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If xml is well formed, below regular expression can be used.&lt;/P&gt;&lt;P&gt;If xml is ill formed, the transformation will fail anyways.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;DATA lv_str TYPE string VALUE '&amp;lt;tag1&amp;gt;&amp;lt;tag2&amp;gt;&amp;lt;tag&amp;gt; &amp;lt;/tag&amp;gt;&amp;lt;tag&amp;gt;asdf&amp;lt;tag&amp;gt;&amp;lt;tag&amp;gt; &amp;lt;/tag&amp;gt;&amp;lt;/tag2&amp;gt;&amp;lt;tag1&amp;gt;'.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;REPLACE ALL OCCURRENCES OF REGEX '&amp;lt;\w+&amp;gt; &amp;lt;/\w+&amp;gt;' IN lv_str WITH ''.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;WRITE lv_str.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 02 Nov 2014 10:38:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658032#M1866909</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2014-11-02T10:38:52Z</dc:date>
    </item>
    <item>
      <title>Re: XML space tag problem in XML simple transformation de-serialization</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658033#M1866910</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Manish,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it seems you code is working fine, but are you sure that it will not delete any other tags.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let me know your comments.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rajesh A.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 02 Nov 2014 11:38:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658033#M1866910</guid>
      <dc:creator>Rajesh_Amirinen</dc:creator>
      <dc:date>2014-11-02T11:38:11Z</dc:date>
    </item>
    <item>
      <title>Re: XML space tag problem in XML simple transformation de-serialization</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658034#M1866911</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It should work fine for well formed xml. Potentially it will also delete occurrences like &lt;EM&gt;&amp;lt;tag&amp;gt; &amp;lt;/anothertag&amp;gt;&lt;/EM&gt; but that is not expected in real xml.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 02 Nov 2014 11:45:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658034#M1866911</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2014-11-02T11:45:13Z</dc:date>
    </item>
    <item>
      <title>Re: XML space tag problem in XML simple transformation de-serialization</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658035#M1866912</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you so much for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Nov 2014 07:18:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/xml-space-tag-problem-in-xml-simple-transformation-de-serialization/m-p/10658035#M1866912</guid>
      <dc:creator>Rajesh_Amirinen</dc:creator>
      <dc:date>2014-11-11T07:18:25Z</dc:date>
    </item>
  </channel>
</rss>

