cancel
Showing results for 
Search instead for 
Did you mean: 

AET: CL_AXT_TABLES_API->DELETE doesn't create BDoc for ERP

Former Member
0 Kudos

Hi there,

we have a requirement to mass populate and delete the data of an extension created via the AXT tool.

While the mass maintenance works well using the different methods of the CL_AXT_TABLES_API class (create_api_instance, get_list, create, save) and Bdocs for ERP are created -  the DELETE method just deletes the entries for which the record_id is provided but doesn't send any update to ERP.

Did you also get some issues deleting records from AXT extensions which are not replicated to erp?

Our coding looks like this:

  LV_TABLE_ID = 'ZTAB0000P2'.

*{ Start up AXT process

  TRY.

      LR_AXT_API = CL_AXT_TABLES_API=>CREATE_API_INSTANCE( IV_TABLE_ID = LV_TABLE_ID ).

    CATCH: CX_AXT_RUNTIME INTO LR_AXT_X_RUNTIME,

           CX_AXT_DATA_NOT_FOUND INTO LR_AXT_X_RUNTIME.

      APPEND LINES OF LR_AXT_X_RUNTIME->MT_MESSAGES TO LT_AXTMESSAGES .

* TODO: Handle these messages!

      RETURN.

  ENDTRY.

  LR_AXT_API->BUFFER_SUBSCRIBE_FOR_REFRESH( ).

...

*  Fetch the current items and some some logic here to check entries are already in the table

      TRY.

          LR_AXT_API->GET_LIST(

            EXPORTING

              IV_PARENT_ID = LV_PARENT_ID

            IMPORTING

              ET_RECORD_ID = LT_AXTK ).

*

        TRY.

            LR_AXT_API->DELETE(

              IT_RECORD_ID        = LT_AXTK ) .

            LR_AXT_API->SAVE( ).

I don't get any error and the record is being deleted form the ext. table but no update for ERP is generated.

Do you have any clue?

I actually also tried another way to delete the record using the CRMXIF_PARTNER_SAVE which also works well but in this case too no update bdoc for ERP is created.

Any hint would be appreciated!

Thank you

Andrea

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi all,

any hint would be helpful!

thank you

andrea

Former Member
0 Kudos

Hi Andrea,

I am not sure why DELETION of AXT Table entries is not creating BDoc. Since this looks like your custom code you can create the BDoc after deletion.

Try to use the same logic used in report BUPA_SEND to send the business partner again via BDoc.

Hope this will be useful.

Regards,

Naresh