<?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: help in sum in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708185#M627587</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Maybe that will wor:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i_table1 type table of your_structure.&lt;/P&gt;&lt;P&gt;i_table2 type table of your_structure.&lt;/P&gt;&lt;P&gt;w_area type your_structure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*select to i_table1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;loop at i_table1 into w_area.
collect w_area into i_table2. " sum all numeric fields
endloop.

append lines of table i_table2 into table i_table1. "in the end you should have a sum&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 19 Aug 2007 16:40:46 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-08-19T16:40:46Z</dc:date>
    <item>
      <title>help in sum</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708180#M627582</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;i have a FM  and i buield stuctre in se 11 with field like h1...see below, and i wont to add to this structre sum of the field that above&lt;/P&gt;&lt;P&gt;how can i do that in my program .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;example&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;h1&lt;DEL&gt;-h2&lt;/DEL&gt;-h3&lt;DEL&gt;-h4&lt;/DEL&gt;-h5---h6&lt;/P&gt;&lt;P&gt;10&lt;DEL&gt;-20&lt;/DEL&gt;-30&lt;DEL&gt;-40&lt;/DEL&gt;-50---60&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;10&lt;DEL&gt;-30&lt;/DEL&gt;-60&lt;DEL&gt;-100&lt;/DEL&gt;150&lt;DEL&gt;210  &amp;lt;&lt;/DEL&gt;----Add this to structre with the sum os the field above&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;how could i do that&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 19 Aug 2007 14:45:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708180#M627582</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-19T14:45:20Z</dc:date>
    </item>
    <item>
      <title>Re: help in sum</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708181#M627583</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi Shnya,&lt;/P&gt;&lt;P&gt;you can define two internal table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i_table1 type table of your_structure.&lt;/P&gt;&lt;P&gt;i_table2 type table of your_structure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*select to i_table1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i_table2 = i_table1. "copy values from table 1 to table 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;collect i_table2. " sum all numeric fields&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;insert lines of table i_table2 into table i_table1. "in the end you should have a sum&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best,&lt;/P&gt;&lt;P&gt;wojciech&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 19 Aug 2007 16:07:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708181#M627583</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-19T16:07:18Z</dc:date>
    </item>
    <item>
      <title>Re: help in sum</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708182#M627584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Shnya,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can achieve this using DO....VARYING FROM statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA V_TOTAL TYPE H1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT ITAB INTO WA.&lt;/P&gt;&lt;P&gt;DO 6 TIMES VARYING V_H FROM WA-H1 NEXT WA-H6.&lt;/P&gt;&lt;P&gt;  V_TOTAL = V_TOTAL + V_H. &lt;/P&gt;&lt;P&gt;  WRITE:/ V_TOTAL.&lt;/P&gt;&lt;P&gt;ENDDO.&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>Sun, 19 Aug 2007 16:11:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708182#M627584</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-19T16:11:58Z</dc:date>
    </item>
    <item>
      <title>Re: help in sum</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708183#M627585</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;i try like u tell but its not working&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND LINES OF planned_hours to planned_hours_tmp .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;COLLECT planned_hours_tmp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;APPEND LINES OF planned_hours_tmp to planned_hours .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 19 Aug 2007 16:30:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708183#M627585</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-19T16:30:06Z</dc:date>
    </item>
    <item>
      <title>Re: help in sum</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708184#M627586</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;i try like u tell but i have dump&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: V_TOTAL TYPE char10 , V_H type char10.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT planned_hours ASSIGNING &amp;lt;wa_p_h&amp;gt;.&lt;/P&gt;&lt;P&gt;DO 12 TIMES VARYING V_H FROM &amp;lt;wa_p_h&amp;gt;-H1 NEXT &amp;lt;wa_p_h&amp;gt;-H12.&lt;/P&gt;&lt;P&gt;V_TOTAL = V_TOTAL + V_H.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this is the error &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  The program terminated while the 3 loop pass was being executed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you cannot solve the problem yourself and yo&lt;/P&gt;&lt;P&gt;an error message to SAP, include the following&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. A printout of the problem description (short&lt;/P&gt;&lt;P&gt;   To obtain this, select in the current displa&lt;/P&gt;&lt;P&gt;   Save-&amp;gt;Local File (unconverted)".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. A suitable printout of the system log&lt;/P&gt;&lt;P&gt;   To obtain this, call the system log through&lt;/P&gt;&lt;P&gt;   Limit the time interval to 10 minutes before&lt;/P&gt;&lt;P&gt;   after the short dump. In the display, then s&lt;/P&gt;&lt;P&gt;   "System-&amp;gt;List-&amp;gt;Save-&amp;gt;Local File (unconverted&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. If the programs are your own programs or mod&lt;/P&gt;&lt;P&gt;   supply the source code.&lt;/P&gt;&lt;P&gt;   To do this, select the Editor function "Furt&lt;/P&gt;&lt;P&gt;   Upload/Download-&amp;gt;Download".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. Details regarding the conditions under which&lt;/P&gt;&lt;P&gt;   or which actions and input led to the error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thankes&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 19 Aug 2007 16:38:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708184#M627586</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-19T16:38:48Z</dc:date>
    </item>
    <item>
      <title>Re: help in sum</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708185#M627587</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Maybe that will wor:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i_table1 type table of your_structure.&lt;/P&gt;&lt;P&gt;i_table2 type table of your_structure.&lt;/P&gt;&lt;P&gt;w_area type your_structure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*select to i_table1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;loop at i_table1 into w_area.
collect w_area into i_table2. " sum all numeric fields
endloop.

append lines of table i_table2 into table i_table1. "in the end you should have a sum&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 19 Aug 2007 16:40:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-in-sum/m-p/2708185#M627587</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-19T16:40:46Z</dc:date>
    </item>
  </channel>
</rss>

