2009 May 27 11:42 AM
Hi all!. We are calling bapi_network_maintain in our development as_
bapi_network_maintain (...)
source code
bapi_network_maintain (...)
source code...
First we tried to use bapi_transaction_commit with wait = X and we had locks problem.
After we tried to use wait up to 1 second instead bapi_transaction_commit and in our development system worked. But now we transport the report to our test system and it doesn't work.
As you imagine a wait up to 2 second is not the solution.
Also we saw that bapi_network_maintain has in its code commit included but not all of them are with wait option. So we don't know if this could be a problem but we thinks more people could have our same issue!.
Pleaaaaaseeeeee, help!!!!
Thanks a lot,
Ana.
2009 May 27 11:49 AM
Hi,
Try as follows:-
CALL FUNCTION 'BAPI_NETWORK_MAINTAIN'
IMPORTING
RETURN = itab_return
TABLES
i_method_project = itab
EXCEPTIONS
OTHERS = 35.
Regards,
Ankur Parab
2009 May 27 11:52 AM
hai,
as the data base locks are not released and u r trying to call again the bapi ,
there is no need to use separate transaction commit for the same , just instead of using save method use saveand wait method , and instead of callign separately why dont u call mulitple networks with single bapi call,
regards
m.a
2009 May 28 8:46 AM
It's a long history.
We need to change dates for all networks in a project. So we realised only dates are correct if we call bapi_network_maintain twice. We send a message to SAP and they tell us is caused for our customizing. For me is not a correct behaviour because in online transaction it works fine, but arguing with SAP is very hard, so finally we put two calls and it works. The problem is we have to put wait up to 1 second between calls to bapi_network_maintain and it seems one seconds are not always enough...
Aggggg!!!! sometimes simple things in abap become so difficult....
Thanks for your help!!!!!!!!
2009 May 28 9:11 AM
hai ,
you are right u face a problem for this, due to customising automatically dates are fetched based on project profile , and u have to update it again, we too faced the same problem as actual dates were not updated when activites were created as the dates were assigned due to customisin so again we called the bapi to update the dates , so u have to wait till the earlier data is written in data base,
and if for the same if u try in debug it will run successfully even though u ditn maintian any wait,
so u haev to provide wait statement between two calls and it depends on how much data u r writing in sap, we were able to write around 2000 to 5000 activities at a time, u cn aprovide wait up to 5 seconds which will be fien enough
regards
m.a