08-29-2014 6:08 PM
Experts,
I have one requirement where invoice document is being posted via FB01 using INVOIC01 IDOC.
When this IDOC is processed one document is posted, My requirement is to populate Reporting Country at item level (Which comes in addition data tab).
I have searched a lot before posting this thread. Could you please suggest how to achieve the same.
08-29-2014 6:11 PM
08-29-2014 6:11 PM
08-29-2014 6:13 PM
08-29-2014 6:25 PM
I believe you can try to transfer it by an user-exit (EXIT_SAPLIEDI_101 or EXIT_SAPLIEDI_111)
Max
08-29-2014 6:33 PM
these Exits have following parameters:
I have tried almost all possible fields in that but not getting the desired result.
call customer-function '101'
exporting idoc_contrl_index = idoc_contrl_index
idoc_data_index = idoc_data_index
document_line = akt_belegzeile
importing i_fimsg = user_msg
tables idoc_contrl = idoc_contrl
idoc_data = idoc_data
document_data = beleg_daten
tax_data = steuer_daten
additional_data = zusatz_daten
08-29-2014 6:44 PM
call customer-function '101'
exporting idoc_contrl_index = idoc_contrl_index
idoc_data_index = idoc_data_index
document_line = akt_belegzeile
importing i_fimsg = user_msg
tables idoc_contrl = idoc_contrl
idoc_data = idoc_data
document_data = beleg_daten
tax_data = steuer_daten
additional_data = zusatz_daten
I've never used it, but I believe this IDOC post the document by BI, so it need to transfer the additional fields in BI format (like table BDCDATA):
The structure of DOCUMENT_DATA is structurated like FTPOST1:
STYPE | STYPE_PI |
COUNT | NUM06 |
FNAM | BDC_FNAM |
FVAL | BDC_FVAL |
FVAL_P | BDC_FVAL_P |
As you can see, here it can move the field and the value
Max
08-29-2014 6:48 PM
I tried BSEG-EGMLD with desired value but didnt get the expected result. I believe It should work but not sure what mistake am I doing.
08-29-2014 6:51 PM
08-29-2014 7:09 PM
STYPE | STYPE_PI = P |
COUNT | NUM06 = 0002 |
FNAM | BDC_FNAM = BSEG-EGMLD |
FVAL | BDC_FVAL = 'BE' |
FVAL_P | BDC_FVAL_P = BLANK |
Also I tried RF05L-EGMLD as RF05L is the work area for desired SAP screen.
Both Didn't work.
08-29-2014 7:23 PM
The idoc should be called the fm POSTING_INTERFACE_DOCUMENT in order to create a BI session, try to set a break-point here and check if there's your field (T_FTPOST)
Max
08-30-2014 6:47 AM
06-02-2015 8:52 AM
This is exactly the same requirement as I have. Just with INVOIC02 instead of INVOIC01
Shyam - how did you solve the requirement of getting reporting country in the document when posting via IDOC?
06-08-2015 6:50 AM
Hi Rene,
I got the results by adding one more record in beleg_daten internal table in below exit .
(EXIT_SAPLIEDI_101)
call customer-function '101'
exporting idoc_contrl_index = idoc_contrl_index
idoc_data_index = idoc_data_index
document_line = akt_belegzeile
importing i_fimsg = user_msg
tables idoc_contrl = idoc_contrl
idoc_data = idoc_data
document_data = beleg_daten
tax_data = steuer_daten
additional_data = zusatz_daten
Record Added :
STYPE | STYPE_PI = P |
COUNT | NUM06 = 0002 |
FNAM | BDC_FNAM = BSEG-EGMLD |
FVAL | BDC_FVAL = 'BE' |
FVAL_P | BDC_FVAL_P = BLANK |
Hope that will help you , you can modify the data as per your requirement .
Regards,
Shyam Sunder