Application Development 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: 

BAPI_COSTCENTER_CHANGEMULTIPLE - Change Valid To

SimoneMilesi
Active Contributor
0 Kudos

Hi all!

I'm trying to use the BAPI in object to massively change the Valid To field in cost centers

I filled only my relevant fields (i think, no help in the BAPI!)

Plus the the LogSystem (took from t000).

When I run it, I got no result in Return table and data is not updated (yes, I put BAPI_TRANSACTION_COMMIT 🙂 ).

So I tried to debug a bit and I found that every check is succesfully passed and the method SAVE is invoked (version is 'A')

 if master_data_inactive = space.
* default: active save
 ld_vers = lcl_act_state=>version-active.
 else.
* save an inactive version
 ld_vers = lcl_act_state=>version-inactive.
 endif.
 call method go_application->save
 exporting
 pd_version = ld_vers.

This class is the implementation of the code in include FKMAXCI4

METHOD lif_mdbc~save.
 DATA: ls_dline TYPE t_dline,
 ld_success TYPE boolean. " P9CK134828
 pd_success = true. " P9CK134828
 LOOP AT mt_directory INTO ls_dline.
 CALL METHOD ls_dline-obref->save
 EXPORTING pd_version = pd_version
 IMPORTING pd_success = ld_success. " P9CK134828
 IF NOT ld_success = true. " P9CK134828
 CLEAR pd_success. " P9CK134828
 ENDIF. " P9CK134828
 ENDLOOP.
 ENDMETHOD. " LIF_MDBC~SAVE

and the method CALL METHOD ls_dline-obref->save

looks like this

Since SAVE_ACTION is initial, no data is saved.

So, basically, the BAPI return no message or info, but data is not updated.

Any hint?

Ty

Simone

0 REPLIES 0