‎2012 Mar 06 2:58 AM
Hi,
I am trying to create sales orders for each schedule line items while inquiry creation.
This I have done in the user exit in the VA11 program MV45AFF using BAPI "BAPI_SALESORDER_CREATEFROMDAT2".
along with the Inquiry, Sales orders are also getting created. But I am facing 2 problems.
1) BAPI is not returning the sales order number to the program but when checked from SE37 it is returning the sales order
number.
2) It is not updating the VBFA (SD flow) table.
Regards,
Krishna.
‎2012 Mar 06 3:09 AM
Hi Krishna,
Are you getting any errors in the return table ? , if not possibly there is no commit happening .
Regards,
Ratheesh BS
‎2012 Mar 06 5:46 AM
Hi Ratheesh,
It is not returning any errors. In the return table, finally it gives 'Successfully created.' I am also using CALL FUNCTION 'BAPI_TRANSACTION_COMMIT' after calling the SO creation BAPI.
Regards,
Krishna.
‎2012 Mar 06 6:46 AM
Hello,
1) BAPI is not returning the sales order number to the program but when checked from SE37 it is returning the sales order
number.
- are you passing simulation parameter (TESTRUN) as 'X'
2) It is not updating the VBFA (SD flow) table.
- Please use BAPI_SALESDOCUMENT_COPY for copying and updating VBFA table
Thanks
Krish
‎2012 Dec 12 2:13 AM
Hi Krish,
I am also facing the same problem..can you please let me know how the problem is solved, if solved.
Regards,
Sri.
‎2012 Mar 07 8:24 AM
Are you importing the correct import parameters which return the document number ?
IMPORTING
SALESDOCUMENT = SALESDOCUMENTRegards,
Dev.
‎2012 Mar 08 12:36 PM
Hi Dev,
I have declared a variable lv_number TYPE bapivbeln-vbeln and using this variable to hold the generated sales order document number.
Regards,
Krishna.
‎2012 Mar 08 5:43 PM
Hi,
please paste the part of your code where you are doing the bapi call . i't enable us to better analyse the issue.
Dev.
‎2012 Mar 08 1:17 PM
Hi,
You can use the FM : RV_XVBFA_MAINTAIN to update the document flow explicitly incase if you want.
Regards
Rajesh V