‎2015 Nov 24 4:25 PM
Hi,
I am facing some issue in using BAPI_PO_CHANGE to change Downpayment fields, I have passed relevent values to fields in ls_bapimepoheader and change indicators in ls_bapimepoheaderx. But I am getting SYST: Date 00/00/0000 not expected error. i tried to change some other fields from BAPI it was working fine also I was able to change fields from ME22N.
CALL FUNCTION 'BAPI_PO_CHANGE'
EXPORTING
purchaseorder = is_ekko-ebeln
poheader = ls_bapimepoheader
poheaderx = ls_bapimepoheaderx
no_messaging = 'X'
TABLES
return = lt_return
poitem = lt_bapimepoitem
poitemx = lt_bapimepoitemx.
Regards,
Ankitesh Khare
‎2015 Nov 25 9:02 AM
Hi
Did you check the system date format and the format in which you have sent the date, you can check your default date format in SU01 under defaults tab, if that is the issue you can can use the
FM CONVERT_DATE_TO_INTERN_FORMAT .
Hope this helps.
‎2015 Nov 25 10:35 AM
‎2015 Nov 25 12:01 PM
Always pass the dates in BAPI in YYYYMMDD format unless and otherwise stated in FM documentation.
‎2015 Nov 25 12:53 PM
Hi Ankitesh,
Check that all respective date fields are being passed in proper format and do check if any mandatory fields' are not missing.
Cheers,
Varun Sahu
‎2015 Nov 25 12:59 PM
Use Bapi_PO_GETDETAIL first to get POHEADER in your case in a work area.
make required changes to the structure and use the same in BAPI_PO_CHANGE
You can check date format from bapi_po_getdetail as well.