2016 Feb 09 8:51 AM
Hi,
I have a requirement in which I would need to add a custom field to the table FKKVK (Contract account header). The new custom field will need to be updated with data through BAPI_ISUACCOUNT_CREATEFROMDATA. This BAPI has an extension BAPI structure 'BAPI_TE_FKKVK'.
I have appended an .include structure to both the table FKKVK as well as the BAPI extension structure BAPI_TE_FKKVK. Below is the code:
DATA: WA_EXTENSION TYPE BAPIPAREX,
X_BAPI_TE_FKKVK TYPE BAPI_TE_FKKVK
X_BAPI_TE_FKKVK-VKONT = ' '
X_BAPI_TE_FKKVK-ZCATYPE = 'TEST'. (The new custom field which was added.)
MOVE 'BAPI_TE_FKKVK' TO WA_EXTENSION-STRUCTURE.
MOVE X_BAPI_TE_FKKVK TO WA_EXTENSION-VALUEPART1.
APPEND WA_EXTENSION TO EXTENSIONIN.
The issue is value is being taken in the BAPI , but my table is not getting updated with the value in the custom field.
Has anyone faced a similar issue, please let me know any inputs if any.
.
2016 Feb 09 9:34 AM
Hi.
Did you launch the BAPI_TRANSACTION_COMMIT in the end?
Hope to help
Bye
2016 Feb 10 7:20 AM
Yes Rebecca I did add BAPI_TRANSACTION_COMMIT at the end. All the values are getting updated in the table FKKVK, but not my custom field.
2016 Feb 10 11:48 AM
Hi Manuela , to update Z fields, tables parameter TCONTRACTACCOUNTDATA of BAPIISUVKP must have ZFIELDS.
If your FKKVK has this include with the same fields of BAPI_TE_FKKVK then your only exception can be:
if FKKVK-vkont = bapi_te_fkkvk-vkont or
FKKVK-vkont is initial.
Please check this.
Hope to help
Bye
2016 Feb 09 9:44 AM
Hi,
Try passing
X_BAPI_TE_FKKVK-VKONT = CONTRACTACCOUNT( that you are passing to the BAPI ) instead of Space as you would receive the following error if nothing is passed :
Error processing customer data for include CI_FKKVK, contract account
Thanks.
2016 Feb 10 7:21 AM
Hi Sriranjini,
The BAPI I am using is to create a Contract Account. So before calling the BAPI, I will not have the Contract account number. In that case i cannot fill the extension table with the a contract account number prior to calling the BAPI.
2016 Feb 10 7:24 AM
Hi manu dasa,
Please do the SPRO settings and FIELD SELECTION GROUP settings.
Regards,
shareef.
2016 Feb 10 11:05 AM
Hello
Can you check using FM BAPI_CTRACCONTRACTACCOUNT_CR1 for creating contract account instead of the one you are using now.
Regards
Dwaraka
2016 Feb 10 2:16 PM
Hello,
Try setting X_BAPI_TE_FKKVK-VKONT to a blank field of 12 characters length.
K--
2016 Feb 11 11:54 AM