‎2008 Feb 14 10:08 AM
Plz let me know if there is any transaction to compare the fields used in two tables or anyother way to do the same.
just to check the guid and partner id
Like we used to compare two programs in the same screen using SE 39
‎2020 Jan 07 12:09 PM
DDIC tables and views:
Goto SE16 using view DD03VV and specify the two tables you want to compare in selection field TABNAME, then sort by FIELDNAME.
‎2008 Feb 14 10:10 AM
‎2008 Feb 14 10:12 AM
Hi,
We can have one choice that we can compare the contents in 2 internal tables using FM 'CTVB_COMPARE_TABLES'. Just extract the data from those 2 tables and use this function module this will return three internal tables with deleted entries, new entries and modified intries in new table.
Rgds,
Bujji
‎2008 Feb 14 10:14 AM
Hi
Try T-Code SCMP or you can go into the specific table you want to compare (SM31) and select "Utilities" then "Comparison"
Thanks
Vasudha
Edited by: Vasudha L on Feb 14, 2008 11:15 AM
‎2008 Feb 14 10:18 AM
Uma,
IF it_1[] = it_2[]. " Tables contents are the same
ELSE.
" Tables contents are different
ENDIF.
If they have different structure, loop one of the tables, and then read the other in the loop, then compare field by field.
Or if you don't need the contents (just comparing) you can do like this, for example:
LOOP AT it_1 INTO wa_1.
READ TABLE it_2 WITH KEY field2 = wa_1-field2
field5 = wa_1-field5
TRANSPORTING NO FIELDS.
IF sy-subrc = 0.
Records are in both the tables (field2 and field5 are the fields which are common in both tables).
ENDIF.
ENDLOOP.
K.Kiran.
‎2008 Feb 14 12:25 PM
friends,
when i try to execute the FM CTVB_COMPARE_TABLES . i got the following error message.
I want to compare the fields used in two differeent tables..
and not the contents.
Thanks for all ur answers.
Error generating the test frame
Message no. FL819
Diagnosis
The system could not generate a syntactically correct test frame for function module CTVB_COMPARE_TABLES. You therefore cannot test the function module using the test environment. You have probably used an ABAP feature in the interface definition that is not yet supported in the test environment.
The error message is:
"ANY TABLE" expected, not "STANDARD TABLE".
System Response
Procedure
Check whether you can change the interface of the function module so that it is possible to generate the test frame. If this is not possible,you will have to write your own utility for testing the function module.
Procedure for System Administration
‎2008 Jun 19 9:58 AM
Sorry,
I have the problem with function "CTVB_COMPARE_TABLES" that when I have "STRING"-Fields in my table, then it produce a shortdump ASSIGN_CASTING_ILLEGAL_CAST in include LBUSSF00.
(line 95)
**....Prepare key for selection.........................................
<b> **assign <lfs_table_old> to <lfs_table_x> casting. "UNICODE!**</b>
assign <lfs_table_x>(key_length) to <lfs_table_key> casting.
**....Select corresponding record in new table if it is changed.........
WHAT CAN I DO?
‎2020 Jan 07 12:09 PM
DDIC tables and views:
Goto SE16 using view DD03VV and specify the two tables you want to compare in selection field TABNAME, then sort by FIELDNAME.
‎2020 Jan 07 12:32 PM
‎2020 Aug 21 11:29 AM
Thanks Luc, your answer on 12 years old question was helpful to me.