<?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: Comparting Entries in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757684#M328139</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is an example program showing how you can get the data from the other system.  It will come back as comma delimited, you can simply loop this IDATA talble and SPLIT the line into the specific fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

REPORT zrich_0001.

DATA: idfies TYPE TABLE OF dfies WITH HEADER LINE.
DATA: iopt TYPE TABLE OF rfc_db_opt WITH HEADER LINE.
DATA: ifld TYPE TABLE OF rfc_db_fld WITH HEADER LINE.
DATA: idat TYPE TABLE OF tab512 WITH HEADER LINE.

PARAMETERS: p_table TYPE   ddobjname.


CALL FUNCTION 'DDIF_NAMETAB_GET'
  EXPORTING
    tabname   = p_table
  TABLES
    dfies_tab = idfies
  EXCEPTIONS
    not_found = 1
    OTHERS    = 2.

LOOP AT idfies.
  ifld-fieldname = idfies-fieldname.
  APPEND ifld.
ENDLOOP.

CALL FUNCTION 'RFC_READ_TABLE'
     DESTINATION 'TST'       "&amp;lt;- Your RFC Destination to Test system
  EXPORTING
    query_table                = p_table
    delimiter                  = ','
*   NO_DATA                    = ' '
*   ROWSKIPS                   = 0
*   ROWCOUNT                   = 0
  TABLES
    OPTIONS                    = iopt
    fields                     = ifld
    data                       = idat
 EXCEPTIONS
   table_not_available        = 1
   table_without_data         = 2
   option_not_valid           = 3
   field_not_valid            = 4
   not_authorized             = 5
   data_buffer_exceeded       = 6
   OTHERS                     = 7.

LOOP AT idat.
  WRITE:/ idat.
ENDLOOP.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 03 Dec 2006 18:16:22 GMT</pubDate>
    <dc:creator>RichHeilman</dc:creator>
    <dc:date>2006-12-03T18:16:22Z</dc:date>
    <item>
      <title>Comparting Entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757682#M328137</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;     In development we have a z table with 50 entries and in testing environment the same table contains 55 entries. &lt;/P&gt;&lt;P&gt;     My question is, how can i compare the same table in two different environments and see what new entries are added in testing environment?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Dec 2006 18:04:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757682#M328137</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-03T18:04:39Z</dc:date>
    </item>
    <item>
      <title>Re: Comparting Entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757683#M328138</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, since there are only 50 or so,  you can dump both tables to excel sheet, sort them and compare.  If you would like to do this programatticaly, then you will need to create an RFC function module to retrieve the data and bring it back.  Or you can use the RFC function module RFC_READ_TABLE to get the data.  Once you have the data from the target system, you can compare it against the data in your dev system using simply internal table comparison routines.&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;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Dec 2006 18:08:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757683#M328138</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-12-03T18:08:36Z</dc:date>
    </item>
    <item>
      <title>Re: Comparting Entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757684#M328139</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is an example program showing how you can get the data from the other system.  It will come back as comma delimited, you can simply loop this IDATA talble and SPLIT the line into the specific fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

REPORT zrich_0001.

DATA: idfies TYPE TABLE OF dfies WITH HEADER LINE.
DATA: iopt TYPE TABLE OF rfc_db_opt WITH HEADER LINE.
DATA: ifld TYPE TABLE OF rfc_db_fld WITH HEADER LINE.
DATA: idat TYPE TABLE OF tab512 WITH HEADER LINE.

PARAMETERS: p_table TYPE   ddobjname.


CALL FUNCTION 'DDIF_NAMETAB_GET'
  EXPORTING
    tabname   = p_table
  TABLES
    dfies_tab = idfies
  EXCEPTIONS
    not_found = 1
    OTHERS    = 2.

LOOP AT idfies.
  ifld-fieldname = idfies-fieldname.
  APPEND ifld.
ENDLOOP.

CALL FUNCTION 'RFC_READ_TABLE'
     DESTINATION 'TST'       "&amp;lt;- Your RFC Destination to Test system
  EXPORTING
    query_table                = p_table
    delimiter                  = ','
*   NO_DATA                    = ' '
*   ROWSKIPS                   = 0
*   ROWCOUNT                   = 0
  TABLES
    OPTIONS                    = iopt
    fields                     = ifld
    data                       = idat
 EXCEPTIONS
   table_not_available        = 1
   table_without_data         = 2
   option_not_valid           = 3
   field_not_valid            = 4
   not_authorized             = 5
   data_buffer_exceeded       = 6
   OTHERS                     = 7.

LOOP AT idat.
  WRITE:/ idat.
ENDLOOP.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Dec 2006 18:16:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757684#M328139</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-12-03T18:16:22Z</dc:date>
    </item>
    <item>
      <title>Re: Comparting Entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757685#M328140</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Rich. I did award the points.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Dec 2006 21:25:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/comparting-entries/m-p/1757685#M328140</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-12-03T21:25:51Z</dc:date>
    </item>
  </channel>
</rss>

