‎2007 May 03 11:30 AM
hi expert,
when i used this function
module- BAPI_FIXEDASSET_CHANGE
it shows that data has been changed but when i saw in the DB table
its not chang, can you tell me why?
vijay
‎2007 May 03 11:38 AM
Also one thing more to add to this... use it this way....
call function 'BAPI_FIXEDASSET_CHANGE'
exporting
companycode = companycode
asset = asset
subnumber = subnumber
generaldata = generaldata
generaldatax = generaldatax
importing
return = l_bapiret2.
if l_bapiret2-type ne 'E'.
call function 'BAPI_TRANSACTION_COMMIT'
exporting
wait = 'X'
importing
return = l_bapiret2.
else.
call function 'BAPI_TRANSACTION_ROLLBACK'
importing
return = l_bapiret2.
endif.
In debug, the commmit happens automatically after every F5 and hence it actually works in debug.
Try to commit irrespective of the return structure.
Regards,
Jayant Sahu.
<b>Please reward if helpful</b>
‎2007 May 03 11:32 AM
Hi vijay,
1. Since this is a bapi,
2. we have to use this FM
BAPI_TRANSACTION_COMMIT
(after calling your FM)
3. So that data is commited and saved.
(otherwise it won't get saved in database)
regards,
amit m.
‎2007 May 03 11:32 AM
HI..
u need to call commit when using BAPI
FM :<b>BAPI_TRANSACTION_COMMIT</b>
Message was edited by:
Rammohan Nagam
‎2007 May 03 11:35 AM
there are several possibilities for that.
- The BAPI might run in Background task and do the changes not instantly.
- when calling the BAPI there could be some update-flag you have to SET to enable the BAPI to really to the changes.
oh lol yeah and you might have forgotten to call the "BAPI_TRANSACTION_COMMIT" which will get the changes written down to the DB.
Message was edited by:
Florian Kemmer
‎2007 May 03 11:36 AM
Hey Vijay have you used this function module along with that Bapi.
call function 'BAPI_TRANSACTION_COMMIT'
Also if youhave used.. please check the condition in whic you are using it... if the condition you have provided is not true it won't work..
Regards,
Jayant Sahu
<b>Please reward if helpful</b>
‎2007 May 03 11:38 AM
Also one thing more to add to this... use it this way....
call function 'BAPI_FIXEDASSET_CHANGE'
exporting
companycode = companycode
asset = asset
subnumber = subnumber
generaldata = generaldata
generaldatax = generaldatax
importing
return = l_bapiret2.
if l_bapiret2-type ne 'E'.
call function 'BAPI_TRANSACTION_COMMIT'
exporting
wait = 'X'
importing
return = l_bapiret2.
else.
call function 'BAPI_TRANSACTION_ROLLBACK'
importing
return = l_bapiret2.
endif.
In debug, the commmit happens automatically after every F5 and hence it actually works in debug.
Try to commit irrespective of the return structure.
Regards,
Jayant Sahu.
<b>Please reward if helpful</b>