<?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: Internal Tables comparison in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630136#M281289</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, but I took this to be a performance question. If you look at the FM, you'll see that it's doing some looping at the tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 27 Sep 2006 20:01:13 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-09-27T20:01:13Z</dc:date>
    <item>
      <title>Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630129#M281282</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;I have a two internal tables, one is master internal table and the other is duplicate of that master table.I want to compare first internal table fields with other internal table fields If matches i want to delete that entry in the master internal table.&lt;/P&gt;&lt;P&gt;I don't want to use LOOP... ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any other possibility?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;fractal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:04:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630129#M281282</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-27T19:04:52Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630130#M281283</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;  I believe it is not possible to do that without LOOP AT..ENDLOOP...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;THanks,&lt;/P&gt;&lt;P&gt;Naren&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:09:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630130#M281283</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-27T19:09:34Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630131#M281284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;look at the below SAP help link for Comparing Internal Tables:-&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw2004s/helpdata/en/fc/eb3841358411d1829f0000e829fbfe/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw2004s/helpdata/en/fc/eb3841358411d1829f0000e829fbfe/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Sudheer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:12:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630131#M281284</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-27T19:12:16Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630132#M281285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It is not possible to compare individual records of an ITAB without looping at it.. you could loop at one &amp;amp; read the other.. you can use the assignh component option in filed-symbols to make the code efficient..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;~Suresh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:17:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630132#M281285</guid>
      <dc:creator>suresh_datti</dc:creator>
      <dc:date>2006-09-27T19:17:18Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630133#M281286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Fractal&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I recommend to use the same approach as SAP standard uses for creating change documents. In order to do so you need to define two additional itab having a change indicator as shown below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;TYPES: BEGIN OF ty_s_itab_di.  
INCLUDE TYPE struc_a.
TYPES: CHIND  TYPE bu_chind.
TYPES: END OF ty_s_itab_di.
TYPES: ty_t_itab_di  TYPE STANDARD TABLE OF ty_s_itab_di 
                     WITH DEFAULT KEY.
DATA:  
  gt_itab_old  TYPE ty_t_itab_di,


gt_itab_new TYPE ty_t_itab_di.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Fill itabs gt_Itab_old with the corresponding data of itab1 and gt_itab_new with the corresponding data of itab2.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Very important: sort you itabs either by all key fields or by all fields.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Call function CHANGEDOCUMENT_PREPARE_TABLES with the following parameters:&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;- CHECK_INDICATOR = ' ' &lt;/P&gt;&lt;P&gt;- TABLE_NEW = gt_Itab_new&lt;/P&gt;&lt;P&gt;- TABLE_OLD = gt_itab_old&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The function module will remove identical lines from both itabs. New entries in gt_itab_New will have CHIND = 'I' and deleted entries in gt_itab_old will have CHIND = 'D'. If there is a delta between entries having the same keys then CHIND = 'U' (update).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is an extract of the function module's documentation for the TABLES parameter:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt; Table contains the changed data
 
     The table structure must begin with the structure specified under
     TABLENAME and an additional processing flag (TYPE C, length 1).
 
     The table must be passed sorted by key.
 
     During compression, identical lines in TABLE_OLD and TABLE_NEW are
     deleted and the processing flag set. The following cases are
     distinguished:
 
     o   Lines which exist with table key in TABLE_NEW, but not in TABLE_OLD:
         Processing flag = "I" for INSERT.
 
     o   Lines which exist with table key in TABLE_NEW and in TABLE_OLD, the
         contents of the TABLENAME structure fields in TABLE_NEW is not the
         same as in TABLE_OLD: Processing flag = "U" for UPDATE.
 
     o   Lines which exist with table key in TABLE_NEW and in TABLE_OLD, the
         contents of the TABLENAME structure fields in TABLE_NEW is the same
         as in TABLE_OLD: Delete the line in TABLE_NEW, Delete the line in
         TABLE_OLD.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;  Uwe&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:19:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630133#M281286</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2006-09-27T19:19:51Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630134#M281287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You will have to LOOP at one table, but you can then READ the other table. See:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; /people/rob.burbank/blog/2006/02/07/performance-of-nested-loops&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:24:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630134#M281287</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-27T19:24:28Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630135#M281288</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Rob&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As I said before you don't need loop at all. All that is required are the two additional itabs which have to be sorted prior to calling the function module.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;  Uwe&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 19:47:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630135#M281288</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2006-09-27T19:47:37Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630136#M281289</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, but I took this to be a performance question. If you look at the FM, you'll see that it's doing some looping at the tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 20:01:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630136#M281289</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-27T20:01:13Z</dc:date>
    </item>
    <item>
      <title>Re: Internal Tables comparison</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630137#M281290</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Bob&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You are definitely right. Looping must be done, yet at least it's not us who has to do the coding.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;  Uwe&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 20:45:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/internal-tables-comparison/m-p/1630137#M281290</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2006-09-27T20:45:06Z</dc:date>
    </item>
  </channel>
</rss>

