<?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: String Problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131193#M743849</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;sorry I did not read this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can read table IT_NO and use the field NUM to have the values&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anyways i'll try the code and reward you points.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just got another question..&lt;/P&gt;&lt;P&gt;because your the only one helping me out, id like to put points for all your reply.&lt;/P&gt;&lt;P&gt;is it possible or only one option per person reply?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 24 Nov 2007 04:02:47 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-11-24T04:02:47Z</dc:date>
    <item>
      <title>String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131186#M743842</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;str1 = Invoice Reference Number: 111, 222, 333, 444&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to get all the numeric data and set it in the variables .&lt;/P&gt;&lt;P&gt;(variables will have the value of the trimmed numbers).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var1 = 111&lt;/P&gt;&lt;P&gt;var2 = 222&lt;/P&gt;&lt;P&gt;var3 = 333&lt;/P&gt;&lt;P&gt;var4 = 444&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;kindly take note that number of variables may depend on the numbers in the string.&lt;/P&gt;&lt;P&gt;given above, code sets 4  variables(var1, var2, var3 &amp;amp; var4) because there is 4 combination of numbers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;how to do this in code? is it possible to declare variables on looping?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;any help is greatly appreciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:34:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131186#M743842</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T03:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131187#M743843</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can tri with this logic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;REPORT  ZTEST_NP_123.

DATA: STR TYPE STRING.

STR = 'Invoice Reference Number: 111, 222, 333, 444'.

DATA: L_PART1 TYPE STRING,
      L_PART2 TYPE STRING.

DATA: BEGIN OF IT_NO OCCURS 0,
      NUM(10),
      END   OF IT_NO.

SPLIT STR AT ':' INTO L_PART1 L_PART2.

SPLIT L_PART2 AT ',' INTO TABLE IT_NO.

loop at it_no.
  write: / it_no-num.
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:39:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131187#M743843</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-24T03:39:39Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131188#M743844</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;loop at it_no.&lt;/P&gt;&lt;P&gt;  write: / it_no-num.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this code only displays the data..&lt;/P&gt;&lt;P&gt;how can i declare that var1 = 111 etc.?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;take note that the number variables may depend of string number. if there 7 combination of numbers in string, program should declare 7 variables also. did you get me?&lt;/P&gt;&lt;P&gt;thnks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:45:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131188#M743844</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T03:45:22Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131189#M743845</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can read table IT_NO and use the field NUM to have the values&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or change the code like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;data: var1(10),
      var2(10),
      var3(10),
      var4(10),
      var5(10),
      var6(10),
      var7(10).
      

SPLIT STR AT ':' INTO L_PART1 L_PART2.

SPLIT L_PART2 AT ',' INTO var1 var2 var3 var4 var5 var6 var7.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:48:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131189#M743845</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-24T03:48:53Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131190#M743846</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what if there is 100 combination of numbers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;should i declare:&lt;/P&gt;&lt;P&gt;data: var1(10) up to var100(10)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thank you!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:52:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131190#M743846</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T03:52:17Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131191#M743847</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;But instead of this you can use the internal table IT_NO and use the LOOP to read that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Otherwise you have to defind like:&lt;/P&gt;&lt;P&gt;data: var1(10) &lt;/P&gt;&lt;P&gt;var2(10),&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt; var100(10).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:55:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131191#M743847</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-24T03:55:46Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131192#M743848</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Newbie,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can not extend variables in dynamic way but we can achieve this using the help of internal tables. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If your string contains a single common letter which is separating  numerics then SPLIT will be used, otherwise string contains different characters in the string which are separating numerics then use the following code. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ofcourse, this code can be used for both of the cases, but will be relevant for different characters in the string, otherwise SPLIT will be best option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check this code.&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF TY_VAR,&lt;/P&gt;&lt;P&gt;NO(10),&lt;/P&gt;&lt;P&gt;END OF TY_VAR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA IT_VAR TYPE STANDARD TABLE OF TY_VAR WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA V_LENGTH TYPE I.&lt;/P&gt;&lt;P&gt;DATA V_FLAG.&lt;/P&gt;&lt;P&gt;DATA V_POS TYPE I.&lt;/P&gt;&lt;P&gt;DATA V_CHAR.&lt;/P&gt;&lt;P&gt;DATA WA_VAR TYPE TY_VAR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: P_NUMBER TYPE STRING.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;V_LENGTH = STRLEN( P_NUMBER ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DO V_LENGTH TIMES.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;V_CHAR = P_NUMBER+V_POS(1).&lt;/P&gt;&lt;P&gt;IF  V_CHAR CO '0123456789'.&lt;/P&gt;&lt;P&gt;CONCATENATE WA_VAR V_CHAR INTO WA_VAR.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;CLEAR WA_VAR.&lt;/P&gt;&lt;P&gt;V_FLAG = 'X'.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF WA_VAR IS NOT INITIAL AND V_FLAG = 'X'.&lt;/P&gt;&lt;P&gt;APPEND WA_VAR TO IT_VAR.&lt;/P&gt;&lt;P&gt;CLEAR WA_VAR.&lt;/P&gt;&lt;P&gt;CLEAR V_FLAG.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*-Numbers in the string&lt;/P&gt;&lt;P&gt;LOOP AT IT_VAR.&lt;/P&gt;&lt;P&gt;WRITE:/ IT_VAR-NO.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vinay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 03:57:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131192#M743848</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T03:57:19Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131193#M743849</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;sorry I did not read this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can read table IT_NO and use the field NUM to have the values&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anyways i'll try the code and reward you points.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just got another question..&lt;/P&gt;&lt;P&gt;because your the only one helping me out, id like to put points for all your reply.&lt;/P&gt;&lt;P&gt;is it possible or only one option per person reply?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 04:02:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131193#M743849</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T04:02:47Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131194#M743850</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naimesh Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 04:04:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131194#M743850</guid>
      <dc:creator>naimesh_patel</dc:creator>
      <dc:date>2007-11-24T04:04:09Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131195#M743851</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I see. I'll also try your code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you so much ;o)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 04:06:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131195#M743851</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T04:06:13Z</dc:date>
    </item>
    <item>
      <title>Re: String Problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131196#M743852</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;Yes, You can reward points to one or more or all replies to the person who answered to your question.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You  can find answer for your question in this link for the below question.&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;I posted a thread and marked it as a question. Several people replied and gave me useful advice. I'd like to reward points. What do I do?&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/sdn/crphelp" target="test_blank"&gt;https://www.sdn.sap.com/irj/sdn/crphelp&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vinay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 24 Nov 2007 04:16:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/string-problem/m-p/3131196#M743852</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-24T04:16:10Z</dc:date>
    </item>
  </channel>
</rss>

