<?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 sum from cluster table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108949#M1509440</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to make a SUM for a field from KONV table. Making the sum directly doesn't works because konv is a cluster table. What is the code for making the sum from this table?&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>Fri, 09 Jul 2010 08:13:19 GMT</pubDate>
    <dc:creator>was_wasssu</dc:creator>
    <dc:date>2010-07-09T08:13:19Z</dc:date>
    <item>
      <title>sum from cluster table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108949#M1509440</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to make a SUM for a field from KONV table. Making the sum directly doesn't works because konv is a cluster table. What is the code for making the sum from this table?&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>Fri, 09 Jul 2010 08:13:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108949#M1509440</guid>
      <dc:creator>was_wasssu</dc:creator>
      <dc:date>2010-07-09T08:13:19Z</dc:date>
    </item>
    <item>
      <title>Re: sum from cluster table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108950#M1509441</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;You can proceed with normal selection process ie : fetch the data into and internal table and then later&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can loop that particular internal table and collect it into another internal table  to sum up the values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for example :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;         select * from ( your required field which you want )&lt;/P&gt;&lt;P&gt;                   from konv &lt;/P&gt;&lt;P&gt;                    into table it_konv.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if it_konv[] is not initial.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;     loop at it_konv into wa_konv.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;        wa_konv to wa_collect.&lt;/P&gt;&lt;P&gt;collect wa_collect to it_collect.&lt;/P&gt;&lt;P&gt;&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;collect statement will full fill your requirment&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let me know if you need further information&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Satish Boguda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Jul 2010 08:28:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108950#M1509441</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-07-09T08:28:42Z</dc:date>
    </item>
    <item>
      <title>Re: sum from cluster table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108951#M1509442</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can use this  code also :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : LV_EFFECTIVE TYPE KONV-KWERT .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; SELECT KWERT FROM KONV INTO CORRESPONDING FIELDS OF TABLE IT_KONV WHERE KNUMV EQ WA_EKKO-KNUMV&lt;/P&gt;&lt;P&gt;                                      AND   KPOSN EQ  WA_EKPO-EBELP&lt;/P&gt;&lt;P&gt;                                      AND   KSCHL NE 'NAVS'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF IT_KONV IS NOT INITIAL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    LOOP AT IT_KONV INTO WA_KONV.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      LV_EFFECTIVE =    LV_EFFECTIVE + WA_KONV-KWERT .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    ENDLOOP .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ENDIF .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Jul 2010 08:31:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sum-from-cluster-table/m-p/7108951#M1509442</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-07-09T08:31:13Z</dc:date>
    </item>
  </channel>
</rss>

