04-11-2012 8:12 AM
Hi,
I have a situation, we have been given an FI document number, which has been created by an IDOC. Now we have to find the IDOC number from which it was created.
in the relationship browser i check but the idoc number mentiond there is incorrect, it concatenated date and time.
How do i establish a relationship between Idoc and FI document no?
Regards,
Shraddha
04-11-2012 8:35 AM
Hi Shraddha,
To get the Idoc number, go to the table EDIDS. Pass your FI document number to the field STAPA2 then the Idoc number will be returned in the field DOCNUM.
Hope this helps you.
Regards,
Sindhu Pulluru.
04-11-2012 8:35 AM
Hi Shraddha,
To get the Idoc number, go to the table EDIDS. Pass your FI document number to the field STAPA2 then the Idoc number will be returned in the field DOCNUM.
Hope this helps you.
Regards,
Sindhu Pulluru.
04-11-2012 10:19 AM
Hi,
thanks for your reply. But for certain Document numbers i am not getting any entry in th table.
regards
04-11-2012 12:12 PM
Hi,
Did you check my post?? You can try that method also ...
Regards,
Nagaraj
04-11-2012 12:56 PM
Hi,
Thanks for your reply. but i could understand it thru ur suggestion.
Actuall i dont know the idoc number. i have to search it on the basis of the accounting document no.
Regards,
04-11-2012 2:44 PM
ok if you have the ID of object and you are looking for the idoc, then call function module SREL_GET_NEXT_RELATIONS
04-12-2012 6:32 AM
Hi,
You can get the idocs from we02 if you know message type or basic type... You need to specify the date and either message type or basic type .. Once you get the idoc in the data records you can find the accounting document number, However to know which segment is having accounting document number, you need to look the documentation of the message type.. This way you can find the idoc related to accounting document.
Regards,
Nagaraj
04-11-2012 8:36 AM
have a try on the table EDIDS there is field STAPA2 which will hold the document numbers which are created with Idocs. You can get the Idoc number by giving the FI document number there, but the performance will be very high in accessing this table. Restrict the search providing the STATUS = '53' and providing STAPA2 = 'FI Document' number. This field is character 50, so leading spaces and zeros will also be counted.
04-11-2012 9:34 AM
Hi,
First you should know what is the message type, idoc type used for the idoc..Once you get it then go to WE02 transaction code and specify the date along with idoc type.. You will get list of idocs. To know the FI document number, you need to check the documentenation of the message type in WE60. Now take the idoc which you get in WE02 and then check the data record of the idoc and then teh field where the FI document exists which you will know by reading the documentation.
Regards,
Nagaraj
04-11-2012 10:38 AM
call function module IDOC_READ_COMPLETELY
if you get info from EDIDS structure, then take it from there (more efficient)
if you don't get it, then read table parameter EDIDD with the segment name E1BPACHE09 (or the one that you are using to pass the document key) and you will get the original values