<?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: split at carriage Return, Fieldformat string in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415139#M199732</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rich, &lt;/P&gt;&lt;P&gt;I am having problem with this carriage return. I have a record which is split due to a carriage return. I want the record to be together in a single line, i want to check all the records and if there is a carriage return in the line, then i want the record to be in one single line. the file is a tab delimited file. The hex value for the carriage return is hex00d.&lt;/P&gt;&lt;P&gt;Pls help.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 18 Jul 2007 14:49:58 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-07-18T14:49:58Z</dc:date>
    <item>
      <title>split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415133#M199726</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi at all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i've a string field, where some carriage returns (##) occur. Now i want to split this string at the carriage return into a table. Now the question is, how can i split the string at the carriage return??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After the converting the value of the internal table should be concatenated again by carriage return.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for Your help,&lt;/P&gt;&lt;P&gt;Andi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Jun 2006 13:57:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415133#M199726</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-06-14T13:57:53Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415134#M199727</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Something like this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

data: itab type table of string with header line.

split str at CL_ABAP_CHAR_UTILITIES=&amp;gt;CR_LF into table itab.


&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Jun 2006 14:06:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415134#M199727</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-06-14T14:06:55Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415135#M199728</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;u can use &lt;/P&gt;&lt;P&gt;split str at '##' into itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;concatenate itab '##' into str_new.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Jun 2006 14:07:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415135#M199728</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-06-14T14:07:50Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415136#M199729</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;data : a(10),b(10),c(10),d(40).
	D = &amp;#145;Apple##Orange##Banana&amp;#146;.
	Split d at &amp;#145;##&amp;#146; into a b c.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now u need to append the internal table or table where u want to hold these fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;data: begin of itab occurs 0,
first(10),
second(10),
third(10),
end of itab.


itab-first = a.
itab-second = b.
itab-third = c.

append itab.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now u need not even concatenate the string D again as we havent changed its value anywhere&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps, please award points if found helpful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Jun 2006 14:10:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415136#M199729</guid>
      <dc:creator>rahulkavuri</dc:creator>
      <dc:date>2006-06-14T14:10:37Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415137#M199730</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just to clarify,  I don't think that splitting at ## will do it, because this is an internal representation of the carriage return, so it will not recognize it as ##.  You must either use the class attribute above, or the hex value for it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Jun 2006 14:16:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415137#M199730</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-06-14T14:16:41Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415138#M199731</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rich,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i agree with you. Before i posted my question, i tried split at '##'. It doesn't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Andi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Jun 2006 14:40:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415138#M199731</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-06-14T14:40:19Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415139#M199732</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rich, &lt;/P&gt;&lt;P&gt;I am having problem with this carriage return. I have a record which is split due to a carriage return. I want the record to be together in a single line, i want to check all the records and if there is a carriage return in the line, then i want the record to be in one single line. the file is a tab delimited file. The hex value for the carriage return is hex00d.&lt;/P&gt;&lt;P&gt;Pls help.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Jul 2007 14:49:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415139#M199732</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-18T14:49:58Z</dc:date>
    </item>
    <item>
      <title>Re: split at carriage Return, Fieldformat string</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415140#M199733</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hI,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  Check this code this may be of some use.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;begin of change by 0114_temp&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  data: cr type x value '0A', "(carriage return)&lt;/P&gt;&lt;P&gt;        length type sy-fdpos.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;end of change by 0114_temp&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  loop at it_data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;begin of change by 0114_temp&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;search for carriage returns and replace them&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  length = 1.&lt;/P&gt;&lt;P&gt;  do.&lt;/P&gt;&lt;P&gt;    search it_data-sgtxt for cr starting at length.&lt;/P&gt;&lt;P&gt;    if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;       length = length + sy-fdpos .&lt;/P&gt;&lt;P&gt;       replace cr with space into it_data-sgtxt.&lt;/P&gt;&lt;P&gt;       modify it_data index sy-tabix transporting sgtxt.&lt;/P&gt;&lt;P&gt;    else.&lt;/P&gt;&lt;P&gt;       exit.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;  enddo.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Mahesh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Jul 2007 14:58:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/split-at-carriage-return-fieldformat-string/m-p/1415140#M199733</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-18T14:58:52Z</dc:date>
    </item>
  </channel>
</rss>

