<?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 NETWR value in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470641#M221253</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For a particular PO suppose 3100000180 it has 3 line items in EKPO table, the deletion indicator LOEKZ values are L,null,null for 3 line items..now I want to display all line items of that PO ..and condition is if LOEKZ = &amp;#145;L&amp;#146; then make NETWR = &amp;#145;0.00&amp;#146; if not it should take the value which has in NETWR field. And I kept one variable(V_NETWR) where it store all line item NETWR(i.e, sum of all 3 line item NETWR) it should not take L items NETWR but it should add all the LOEKZ = null values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Given below is the code ..but all conditions are not populated can anyone help me out&amp;#133;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Loop at lt_ekpo where ebeln = lt_ekpo-ebeln.&lt;/P&gt;&lt;P&gt;  v_netwr = lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;    IF lt_ekpo-loekz = 'L'.&lt;/P&gt;&lt;P&gt;    move '0.00' to v_netwr.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;    SHIFT v_netwr LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;      v_total1 = v_total1 + lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;      MOVE v_total1 TO v_total.&lt;/P&gt;&lt;P&gt;      SHIFT v_total LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;Endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 30 Aug 2006 09:31:48 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-08-30T09:31:48Z</dc:date>
    <item>
      <title>NETWR value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470641#M221253</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For a particular PO suppose 3100000180 it has 3 line items in EKPO table, the deletion indicator LOEKZ values are L,null,null for 3 line items..now I want to display all line items of that PO ..and condition is if LOEKZ = &amp;#145;L&amp;#146; then make NETWR = &amp;#145;0.00&amp;#146; if not it should take the value which has in NETWR field. And I kept one variable(V_NETWR) where it store all line item NETWR(i.e, sum of all 3 line item NETWR) it should not take L items NETWR but it should add all the LOEKZ = null values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Given below is the code ..but all conditions are not populated can anyone help me out&amp;#133;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Loop at lt_ekpo where ebeln = lt_ekpo-ebeln.&lt;/P&gt;&lt;P&gt;  v_netwr = lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;    IF lt_ekpo-loekz = 'L'.&lt;/P&gt;&lt;P&gt;    move '0.00' to v_netwr.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;    SHIFT v_netwr LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;    &lt;/P&gt;&lt;P&gt;      v_total1 = v_total1 + lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;      MOVE v_total1 TO v_total.&lt;/P&gt;&lt;P&gt;      SHIFT v_total LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;Endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Aug 2006 09:31:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470641#M221253</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-30T09:31:48Z</dc:date>
    </item>
    <item>
      <title>Re: NETWR value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470642#M221254</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;--Please note the below corrections.&lt;/P&gt;&lt;P&gt;--Please check the variable in bold as it should be some other lebelnr and not lt_expo-ebeln.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Loop at lt_ekpo where ebeln = &amp;lt;b&amp;gt;lt_ekpo-ebeln&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;v_netwr = lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF lt_ekpo-loekz = 'L'.&lt;/P&gt;&lt;P&gt;move '0.00' to v_netwr.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SHIFT v_netwr LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*v_total1 = v_total1 + lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;v_total1 = v_total1 + v_netwr.&lt;/P&gt;&lt;P&gt;MOVE v_total1 TO v_total.&lt;/P&gt;&lt;P&gt;SHIFT v_total LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;Endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--Secondly, I would advice to define v_netwr like ekpo-netwr in that case you dont need to use shift statements unless if you wish to display it in some other way as character.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Anurag Bankley&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Anurag Bankley&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Aug 2006 09:35:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470642#M221254</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-30T09:35:11Z</dc:date>
    </item>
    <item>
      <title>Re: NETWR value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470643#M221255</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;LOEKZ  = 'X' or '', i dont know what is 'L'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Prabhu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Aug 2006 09:35:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470643#M221255</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-30T09:35:36Z</dc:date>
    </item>
    <item>
      <title>Re: NETWR value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470644#M221256</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what i understood was,&lt;/P&gt;&lt;P&gt;if LOEKZ &amp;lt;&amp;gt; 'L'.&lt;/P&gt;&lt;P&gt;  then you should make EKP0-NETWR field.&lt;/P&gt;&lt;P&gt;and you want to calculate totals based on LOEKZ = space.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if i am right, check the logic given below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Loop at lt_ekpo where ebeln = lt_ekpo-ebeln.
&amp;lt;b&amp;gt; clear V_NETWR.
IF lt_ekpo-loekz &amp;lt;&amp;gt; 'L'.
v_netwr = lt_ekpo-netwr.
SHIFT v_netwr LEFT DELETING LEADING space.
endif.
IF lt_ekpo-loekz = 'L'.
v_total1 = v_total1 + lt_ekpo-netwr.
MOVE v_total1 TO v_total.
SHIFT v_total LEFT DELETING LEADING space.
endif.&amp;lt;/b&amp;gt;

Endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Srikanth Kidambi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Srikanth Kidambi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Aug 2006 09:39:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470644#M221256</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-30T09:39:38Z</dc:date>
    </item>
    <item>
      <title>Re: NETWR value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470645#M221257</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;    Follow below logic&lt;/P&gt;&lt;P&gt;     delete it_ekpo where loekz = 'L'.&lt;/P&gt;&lt;P&gt;     Now ur internal table will have active po where&lt;/P&gt;&lt;P&gt;     loekz is initial.&lt;/P&gt;&lt;P&gt;         Loop at lt_ekpo where ebeln = lt_ekpo-ebeln.&lt;/P&gt;&lt;P&gt;v_netwr = lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SHIFT v_netwr LEFT DELETING LEADING space.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;v_total1 = v_total1 + lt_ekpo-netwr.&lt;/P&gt;&lt;P&gt;MOVE v_total1 TO v_total.&lt;/P&gt;&lt;P&gt;SHIFT v_total LEFT DELETING LEADING space.&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;      &lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Amole&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Aug 2006 09:41:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470645#M221257</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-30T09:41:35Z</dc:date>
    </item>
    <item>
      <title>Re: NETWR value</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470646#M221258</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you sure the below statement is correct , u r looping the same table which is in where condition??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;Loop at &amp;lt;b&amp;gt;lt_ekpo&amp;lt;/b&amp;gt; where ebeln = &amp;lt;b&amp;gt;lt_ekpo&amp;lt;/b&amp;gt;-ebeln.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Aug 2006 09:43:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/netwr-value/m-p/1470646#M221258</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-30T09:43:32Z</dc:date>
    </item>
  </channel>
</rss>

