Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

IDoc Comparison

Former Member
0 Likes
2,456

Hi,

I have a requirement, such that I have to compare IDocs, generated by 2 different systems for a same input file. How to compare the segments and values of the IDocs in different systems. Please help me out.

Thanks,

M S DhanaLakshmi

5 REPLIES 5
Read only

GauthamV
Active Contributor
0 Likes
1,348

hi,

check using WE02 or WE05 transactions in both the systems.

Read only

Former Member
0 Likes
1,348

Hi,

Thanks for your quicker reply. But i dont want to do it manually, because there are ennumber of IDocs generated. Its is not possible to check manually. Is there any other way like RFC Comparison?

Thanks,

M S DhanaLakshmi

Read only

Former Member
0 Likes
1,348

Hi,

You can create a Y Function module by copying SPI_IDOC_READ which is remote enabled but its Tables are Commented out !!! Crazy....

then just use this the method COMPARE_TABLES in the class CL_REBF_CRGEN_CMP to compare the segments got from your Y function module

Will this help to solve your requirement?

Read only

Former Member
0 Likes
1,348

hiiii

you can use FM IDOC_READ_COMPLETELY.

Then compare the return table paremeters INT_EDIDD.. for comparing two IDOC segments.

regards

twinkal

Read only

Former Member
0 Likes
1,348

Hi,

Plz check.

To get information for a IDoc from database we can use FM ''IDOC_READ_COMPLETELY'' then its return parameters can be used for comparison i.e. ''INT_EDIDD''

CALL FUNCTION 'IDOC_READ_COMPLETELY'
       EXPORTING
            DOCUMENT_NUMBER          = DOCNUM
       IMPORTING
            IDOC_CONTROL             = EDIDC
*         number_of_data_records   =
*         number_of_status_records =
       TABLES
*         INT_EDIDS                =
            INT_EDIDD                = INT_EDIDD
*    EXCEPTIONS
*         DOCUMENT_NOT_EXIST       = 1
*         DOCUMENT_NUMBER_INVALID  = 2
*         OTHERS                   = 3
            .
  IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
  ENDIF.

Thiw will surely help you.

plz reward if useful.

thanks,

dhanashri.

Edited by: Dhanashri Pawar on Jul 10, 2008 12:17 PM