Skip to Content
author's profile photo Former Member
Former Member

Sales order

Friends,

We used std BAPI - "BAPI_SALESORDER_CREATEFROMDAT2" to create Sales order. However after creating sales order when we check it in VA02 sytem gives message as.

SD document 236 is not in the database or has been archived

Message no. V1302

Why?

Thanks

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Jun 16, 2008 at 04:11 AM

    Hi,

    May be the document is not saved after creation. Please debug the program and check. There may be the role of some user exits like USEREXIT_SAVEDOCUMENT* etc.

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Shiv,

      The system issues V1302 if the document number cannot be found (I think in table VBAK). It states that the document is not in the database or has been archived because it has no way of knowing if the document either does not exist or just has been archived.

      This message points to the sales order not being created. Please ensure that if you are running the BAPI from transaction SE37 that you include "BAPI_TRANSACTION_COMMIT" in a test sequence. Otherwise the BAPI will not create an order.

      Please check this.

      Thank you.

      Best regards,

      Ian Kehoe

  • Posted on Jun 16, 2008 at 08:36 AM

    Dear Shiv Patil,

    Most BAPI cannot be used directly,

    because they dont incorporate commit procedure inside the BAPI .

    Ask your ABAPer to to create custom program

    containing the following logic

    " check user authorization

    " fill data order to be saved

    " check data validity

    " call bapi_create-from_dat2 using that data

    " check if call bapi is ok then commit trx

    if sy-subrc = 0.

    COMMIT WORK .

    endif.

    Rgds,

    Tuwuhsih Winedya

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.