<?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: case, end case statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819383#M350367</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi akmal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;chek out this code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Case kshcl.&lt;/P&gt;&lt;P&gt;when 'ZD01'.&lt;/P&gt;&lt;P&gt;discount = my_tab-total - my_tab-discount.&lt;/P&gt;&lt;P&gt;when 'ZD02'.&lt;/P&gt;&lt;P&gt;if kschl = ZD02, discount = my_tab-total * my_tab-discount/100.&lt;/P&gt;&lt;P&gt;end case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you ar looping through the internal table sthen  you can do the same af ter the when statements.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;sateesh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Jan 2007 14:14:18 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-01-04T14:14:18Z</dc:date>
    <item>
      <title>case, end case statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819381#M350365</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt; name of my internal table is my_tab.i need to calculate the discounts depending upon the condition types(KSCHL) FROM KONV TABLE.&lt;/P&gt;&lt;P&gt; WHEN KSCHL = ZDO1 calulation procedure is in percentage&lt;/P&gt;&lt;P&gt;            KSCHL= ZD02   calculation procedure is in fixed amount.&lt;/P&gt;&lt;P&gt;            and so on.....&lt;/P&gt;&lt;P&gt;my_tab has fields &lt;/P&gt;&lt;P&gt;my_tab-total&lt;/P&gt;&lt;P&gt;my_tab-discount&lt;/P&gt;&lt;P&gt;if kschl = ZD01, discount = my_tab-total - my_tab-discount&lt;/P&gt;&lt;P&gt;if kschl = ZD02, discount =  my_tab-total * my_tab-discount/100.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i wanted to know how to use this in CASE AND END CASE statement.&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;akmal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Jan 2007 14:10:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819381#M350365</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-04T14:10:13Z</dc:date>
    </item>
    <item>
      <title>Re: case, end case statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819382#M350366</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi akmal,&lt;/P&gt;&lt;P&gt;loop at my_tab.&lt;/P&gt;&lt;P&gt;Case my_tab-kschl.&lt;/P&gt;&lt;P&gt;when 'Zd01'.&lt;/P&gt;&lt;P&gt;discount = my_tab-total - my_tab-discount.&lt;/P&gt;&lt;P&gt;when 'ZD02'.&lt;/P&gt;&lt;P&gt;discount = my_tab-total * my_tab-discount/100.&lt;/P&gt;&lt;P&gt;endcase.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope it helps u,&lt;/P&gt;&lt;P&gt;keerthi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Jan 2007 14:13:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819382#M350366</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-04T14:13:14Z</dc:date>
    </item>
    <item>
      <title>Re: case, end case statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819383#M350367</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi akmal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;chek out this code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Case kshcl.&lt;/P&gt;&lt;P&gt;when 'ZD01'.&lt;/P&gt;&lt;P&gt;discount = my_tab-total - my_tab-discount.&lt;/P&gt;&lt;P&gt;when 'ZD02'.&lt;/P&gt;&lt;P&gt;if kschl = ZD02, discount = my_tab-total * my_tab-discount/100.&lt;/P&gt;&lt;P&gt;end case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you ar looping through the internal table sthen  you can do the same af ter the when statements.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;sateesh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Jan 2007 14:14:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/case-end-case-statement/m-p/1819383#M350367</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-04T14:14:18Z</dc:date>
    </item>
  </channel>
</rss>

