<?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 Internal table problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180969#M463735</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;I am getting all the material classification into to a itab using this FM VC_I_GET_CONFIGURATION&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now my problem is first i have to check for a paticular characteristic name(PPG GROUP) which has the given value (RR PLANNER). If it is there i have to again check for the tools and its values, now here goes a loop and a check stmt for PPG GROUP and again inside that i have to loop again, so to avoid this how do i write the logic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Char name                            char value&lt;/P&gt;&lt;P&gt;FIRST_POSITION_TOOL. &lt;/P&gt;&lt;P&gt;PACK_IMPRINT_TOOL&lt;/P&gt;&lt;P&gt;INS_1_TOOL                        12356&lt;/P&gt;&lt;P&gt;INS_2_TOOL                        54568&lt;/P&gt;&lt;P&gt;INS_3_TOOL&lt;/P&gt;&lt;P&gt;PPG_GROUP                          RR PLANNER&lt;/P&gt;&lt;P&gt;INS_4_TOOL&lt;/P&gt;&lt;P&gt;INS_5_TOOL&lt;/P&gt;&lt;P&gt;INS_6_TOOL                         456546&lt;/P&gt;&lt;P&gt;INS_7_TOOL&lt;/P&gt;&lt;P&gt;INS_8_TOOL&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sample code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT i_conf.&lt;/P&gt;&lt;P&gt;          CASE i_conf-atbez.&lt;/P&gt;&lt;P&gt;            WHEN 'PPG_PRODUCT_GROUP'.&lt;/P&gt;&lt;P&gt;               IF i_conf-atwrt = 'RR_PLANNER'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;              LOOP AT i_conf.&lt;/P&gt;&lt;P&gt;                  CASE i_conf-atbez.&lt;/P&gt;&lt;P&gt;                    WHEN 'FIRST_POSITION_TOOL'.&lt;/P&gt;&lt;P&gt;                      IF i_conf-atwrt &amp;lt;&amp;gt; ' ' AND i_conf-atwrt &amp;lt;&amp;gt; '?'.&lt;/P&gt;&lt;P&gt;                        MOVE i_conf-atwrt TO l_atwrt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                        SELECT SINGLE mstae INTO lwa_mara FROM mara&lt;/P&gt;&lt;P&gt;                                              WHERE matnr = l_atwrt.&lt;/P&gt;&lt;P&gt;                        if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;                          if lwa_mara = 'TR'.&lt;/P&gt;&lt;P&gt;                            set = 'X'.&lt;/P&gt;&lt;P&gt;                          endif.&lt;/P&gt;&lt;P&gt;                        endif.&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;                    WHEN 'PACK_IMPRINT_TOOL'.&lt;/P&gt;&lt;P&gt;                      IF i_conf-atwrt &amp;lt;&amp;gt; ' ' AND i_conf-atwrt &amp;lt;&amp;gt; '?'.&lt;/P&gt;&lt;P&gt;                        MOVE i_conf-atwrt TO l_atwrt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                        SELECT SINGLE mstae INTO lwa_mara FROM mara&lt;/P&gt;&lt;P&gt;                                              WHERE matnr = l_atwrt.&lt;/P&gt;&lt;P&gt;                        if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;                          if lwa_mara = 'TR'.&lt;/P&gt;&lt;P&gt;                            set = 'X'.&lt;/P&gt;&lt;P&gt;                          endif.&lt;/P&gt;&lt;P&gt;                        endif.&lt;/P&gt;&lt;P&gt;                      endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                      WHEN 'INS_1_TOOL'.&lt;/P&gt;&lt;P&gt;                      IF i_conf-atwrt &amp;lt;&amp;gt; ' ' AND i_conf-atwrt &amp;lt;&amp;gt; '?'.&lt;/P&gt;&lt;P&gt;                        MOVE i_conf-atwrt TO l_atwrt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it goes on, Can anybody give me a performance way to write this or to avoid loop inside loop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Senthil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 10 May 2007 13:45:43 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-05-10T13:45:43Z</dc:date>
    <item>
      <title>Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180969#M463735</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;I am getting all the material classification into to a itab using this FM VC_I_GET_CONFIGURATION&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now my problem is first i have to check for a paticular characteristic name(PPG GROUP) which has the given value (RR PLANNER). If it is there i have to again check for the tools and its values, now here goes a loop and a check stmt for PPG GROUP and again inside that i have to loop again, so to avoid this how do i write the logic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Char name                            char value&lt;/P&gt;&lt;P&gt;FIRST_POSITION_TOOL. &lt;/P&gt;&lt;P&gt;PACK_IMPRINT_TOOL&lt;/P&gt;&lt;P&gt;INS_1_TOOL                        12356&lt;/P&gt;&lt;P&gt;INS_2_TOOL                        54568&lt;/P&gt;&lt;P&gt;INS_3_TOOL&lt;/P&gt;&lt;P&gt;PPG_GROUP                          RR PLANNER&lt;/P&gt;&lt;P&gt;INS_4_TOOL&lt;/P&gt;&lt;P&gt;INS_5_TOOL&lt;/P&gt;&lt;P&gt;INS_6_TOOL                         456546&lt;/P&gt;&lt;P&gt;INS_7_TOOL&lt;/P&gt;&lt;P&gt;INS_8_TOOL&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sample code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT i_conf.&lt;/P&gt;&lt;P&gt;          CASE i_conf-atbez.&lt;/P&gt;&lt;P&gt;            WHEN 'PPG_PRODUCT_GROUP'.&lt;/P&gt;&lt;P&gt;               IF i_conf-atwrt = 'RR_PLANNER'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;              LOOP AT i_conf.&lt;/P&gt;&lt;P&gt;                  CASE i_conf-atbez.&lt;/P&gt;&lt;P&gt;                    WHEN 'FIRST_POSITION_TOOL'.&lt;/P&gt;&lt;P&gt;                      IF i_conf-atwrt &amp;lt;&amp;gt; ' ' AND i_conf-atwrt &amp;lt;&amp;gt; '?'.&lt;/P&gt;&lt;P&gt;                        MOVE i_conf-atwrt TO l_atwrt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                        SELECT SINGLE mstae INTO lwa_mara FROM mara&lt;/P&gt;&lt;P&gt;                                              WHERE matnr = l_atwrt.&lt;/P&gt;&lt;P&gt;                        if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;                          if lwa_mara = 'TR'.&lt;/P&gt;&lt;P&gt;                            set = 'X'.&lt;/P&gt;&lt;P&gt;                          endif.&lt;/P&gt;&lt;P&gt;                        endif.&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;                    WHEN 'PACK_IMPRINT_TOOL'.&lt;/P&gt;&lt;P&gt;                      IF i_conf-atwrt &amp;lt;&amp;gt; ' ' AND i_conf-atwrt &amp;lt;&amp;gt; '?'.&lt;/P&gt;&lt;P&gt;                        MOVE i_conf-atwrt TO l_atwrt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                        SELECT SINGLE mstae INTO lwa_mara FROM mara&lt;/P&gt;&lt;P&gt;                                              WHERE matnr = l_atwrt.&lt;/P&gt;&lt;P&gt;                        if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;                          if lwa_mara = 'TR'.&lt;/P&gt;&lt;P&gt;                            set = 'X'.&lt;/P&gt;&lt;P&gt;                          endif.&lt;/P&gt;&lt;P&gt;                        endif.&lt;/P&gt;&lt;P&gt;                      endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                      WHEN 'INS_1_TOOL'.&lt;/P&gt;&lt;P&gt;                      IF i_conf-atwrt &amp;lt;&amp;gt; ' ' AND i_conf-atwrt &amp;lt;&amp;gt; '?'.&lt;/P&gt;&lt;P&gt;                        MOVE i_conf-atwrt TO l_atwrt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it goes on, Can anybody give me a performance way to write this or to avoid loop inside loop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Senthil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 May 2007 13:45:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180969#M463735</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-10T13:45:43Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180970#M463736</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you not just do a read?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;read table i_conf with key atbez = 'PPG_PRODUCT_GROUP'&lt;/P&gt;&lt;P&gt;                                      atwrt = 'RR_PLANNER'.&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;  loop at i_conf.&lt;/P&gt;&lt;P&gt;    . . .&lt;/P&gt;&lt;P&gt;  endloop.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 May 2007 13:54:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180970#M463736</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-10T13:54:59Z</dc:date>
    </item>
    <item>
      <title>Re: Internal table problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180971#M463737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;AJP,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have more than one value for the PPG_PRODUCT_GROUP like CALENDERS, DESKPAD and so on, the first loop is for this sake.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Senthil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 May 2007 13:58:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-table-problem/m-p/2180971#M463737</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-10T13:58:04Z</dc:date>
    </item>
  </channel>
</rss>

