<?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: Looping selection screen table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879734#M1478341</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 need to have the exact values of the select-options. So put in an internal table the value of profit center&lt;/P&gt;&lt;P&gt;select prctr into table t_tab from cepc where prctr in s_prctr&lt;/P&gt;&lt;P&gt;after you can loop on your second tab and read the table t_tab to find the values out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like something like this:&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;read table t_tab with key prctr = itab-prctr.&lt;/P&gt;&lt;P&gt;if not sy-subrc is initial.&lt;/P&gt;&lt;P&gt;--&amp;gt; you find it&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&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;i hope it's helpful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 19 May 2010 09:00:21 GMT</pubDate>
    <dc:creator>sylvain_vels</dc:creator>
    <dc:date>2010-05-19T09:00:21Z</dc:date>
    <item>
      <title>Looping selection screen table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879732#M1478339</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;&lt;/P&gt;&lt;P&gt;The selection screen has a select-option input field for Profit Center (S_PRCTR).&lt;/P&gt;&lt;P&gt;Hence user can enter the value like 1000 to 1200 in the selection screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now in the Program, one internal table has list of Profit centers.&lt;/P&gt;&lt;P&gt;ex: ITAB will have following profit centers.&lt;/P&gt;&lt;P&gt;1000, 1001, 1002, 1200&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, i would like to know which are the Profit centers that are missing in the ITAB from S_PRCTR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How to write the logic?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Pavan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 May 2010 08:47:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879732#M1478339</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-05-19T08:47:19Z</dc:date>
    </item>
    <item>
      <title>Re: Looping selection screen table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879733#M1478340</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;
itab1[] = itab[].
delete itab1 where prctr in s_prctr.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The matched record will be deleted from itab1 and the unmatched record remains in itab1.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 May 2010 08:55:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879733#M1478340</guid>
      <dc:creator>kesavadas_thekkillath</dc:creator>
      <dc:date>2010-05-19T08:55:24Z</dc:date>
    </item>
    <item>
      <title>Re: Looping selection screen table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879734#M1478341</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 need to have the exact values of the select-options. So put in an internal table the value of profit center&lt;/P&gt;&lt;P&gt;select prctr into table t_tab from cepc where prctr in s_prctr&lt;/P&gt;&lt;P&gt;after you can loop on your second tab and read the table t_tab to find the values out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like something like this:&lt;/P&gt;&lt;P&gt;loop at itab.&lt;/P&gt;&lt;P&gt;read table t_tab with key prctr = itab-prctr.&lt;/P&gt;&lt;P&gt;if not sy-subrc is initial.&lt;/P&gt;&lt;P&gt;--&amp;gt; you find it&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&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;i hope it's helpful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 May 2010 09:00:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879734#M1478341</guid>
      <dc:creator>sylvain_vels</dc:creator>
      <dc:date>2010-05-19T09:00:21Z</dc:date>
    </item>
    <item>
      <title>Re: Looping selection screen table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879735#M1478342</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Keshav... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But in the selection screen, the user will be entering a range.. like 1000 to 1200.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The internal table ITAB in the Program will have list of Profit centers like 1000, 1001, 1002, 1150, 1200.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NOw, how can i list out the Profit centers which are missing in the ITAB within that selection screen range???&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would like list out the missing profit centers like 1003, 1004,.........1049, 1051,.......1199.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Pavan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 May 2010 09:01:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879735#M1478342</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-05-19T09:01:13Z</dc:date>
    </item>
    <item>
      <title>Re: Looping selection screen table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879736#M1478343</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can try my solution&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 May 2010 09:04:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879736#M1478343</guid>
      <dc:creator>sylvain_vels</dc:creator>
      <dc:date>2010-05-19T09:04:07Z</dc:date>
    </item>
    <item>
      <title>Re: Looping selection screen table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879737#M1478344</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Pavan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in your select-option field you've got a range of profit centers that need to be checked - use it in select statement on table CEPC, then you get all existing profit centers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;compare the result with values in your itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reagards&lt;/P&gt;&lt;P&gt;rea&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 May 2010 09:11:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-selection-screen-table/m-p/6879737#M1478344</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-05-19T09:11:04Z</dc:date>
    </item>
  </channel>
</rss>

