<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110506#M1362100</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the BADI is triggered u make check what's happens after calling the fm FI_DUPLICATE_INVOICE_CHECK, if it returns a SY-BURC different from 0, u call the fm BALW_BAPIRETURN_GET2 in order to append the error message in table RETURN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This table has all messages and if there's a message type E or A, the document won't be posted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So u need to check which message is returned in the BAPI paramenter RETURN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the invoice was just posted u should find out the message 117 of class F5, if in your customizing this message is set as type ERROR, any document will be posted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now your WD should display the messages returned by the BAPI&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 04 Sep 2009 12:18:43 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-09-04T12:18:43Z</dc:date>
    <item>
      <title>BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110471#M1362065</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have been working on BAPI_ACC_DOCUMENT_POST bapi to create a WD application for creating an invoice similar to Tcode FB10. My issue is:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The BAPI_ACC_DOCUMENT_POST" bapi is allowing the end user to make duplicate invoice payments which is not acceptable. We need the BAPI to return an error message if a duplicate entry exists. For eg:- If we enter a duplicate entry in FB10 it throws an error message telling the user that a duplicate entry exists. But, this is not happening in the case of the BAPI.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could anyone help me in finding a way to check for duplicate invoice entries and throw an error message. I would greately appreciate your help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal Yarlagadda.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 15:33:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110471#M1362065</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T15:33:17Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110472#M1362066</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is it not just a warning in FB10?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 15:42:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110472#M1362066</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T15:42:18Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110473#M1362067</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In generally it means to check if there's an invoice with the same reference, so try to check the entries in BSIP table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 15:44:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110473#M1362067</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T15:44:29Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110474#M1362068</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Rob,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;No, in FB10 it is an error message "Check whether document has already been entered under number 1000 600000188 2009".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think this has been configured in  our system as a custom configuration.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 15:47:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110474#M1362068</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T15:47:50Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110475#M1362069</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That msg can be customized as warning or error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyway the main fields of vendor invoice are stored in BSIP table, u can check this table in order to know if an invoice was just posted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 15:57:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110475#M1362069</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T15:57:21Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110476#M1362070</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Max,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your reply. I checked in the table BSIP and I can see the duplicate entries being created. My problem is:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Our system is not allowing duplicate entries through tcode:- FB10 or FB60. But, when when we enter an invoice through a Webdynpro Application created through BAPI_ACC_DOCUMENT_POST bapi, the BAPI is not returning any error message about the duplicate entries. Could you please help me about this problem. I would greatly appreciate your help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regard,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 16:06:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110476#M1362070</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T16:06:17Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110477#M1362071</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;just a thought: try out the same scenario by wrting a Z report prog. or in SE37, then check their results. Also check Cross company code flag, multiple currencies, posting keys&lt;/P&gt;&lt;P&gt;thanq&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: SAP ABAPer on Sep 3, 2009 6:27 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 16:22:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110477#M1362071</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T16:22:01Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110478#M1362072</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The BAPI doesn't call the fm FI_DUPLICATE_INVOICE_CHECK in order to check the posting: I was the same problem and I solved it by the BTE RWBAPI01, usually used to transfer the extension data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If your release is ECC 6 u can also use the BADI acc_document (method change).&lt;/P&gt;&lt;P&gt;If you use the BTE u need to use a record dummy for extension in order to trigger the BTE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the code (Step 1):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;.FUNCTION Z_SDFI_INTERFACE_RWBAPI01.
*"----------------------------------------------------------------------
*"*"Interfaccia locale:
*"  TABLES
*"      IT_ACCIT STRUCTURE  ACCIT
*"      IT_ACCCR STRUCTURE  ACCCR
*"      RETURN STRUCTURE  BAPIRET2
*"      EXTENSION STRUCTURE  BAPIACEXTC
*"      IT_ACCWT STRUCTURE  ACCIT_WT
*"  CHANGING
*"     VALUE(DOCUMENT_HEADER) LIKE  ACCHD STRUCTURE  ACCHD
*"----------------------------------------------------------------------
............................
  LOOP AT IT_ACCIT WHERE KOART = 'K'.

    IT_ACCIT-XUMSW = 'X'.
    MODIFY IT_ACCIT.

    SELECT SINGLE REPRF FROM LFB1 INTO _REPRF
                                           WHERE LIFNR = IT_ACCIT-LIFNR
                                             AND BUKRS = IT_ACCIT-BUKRS.
    IF SY-SUBRC &amp;lt;&amp;gt; 0.
      CLEAR _REPRF.
    ENDIF.

    READ TABLE IT_ACCCR WITH KEY POSNR = IT_ACCIT-POSNR.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 16:45:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110478#M1362072</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T16:45:57Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110479#M1362073</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The BAPI may not be returning it as an "Error" message but it may be there in the return table as a warning message. Please check the return table for all the messages.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 16:46:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110479#M1362073</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T16:46:12Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110480#M1362074</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;......Step 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL FUNCTION 'FI_DUPLICATE_INVOICE_CHECK'
         EXPORTING
              I_BUKRS       = IT_ACCIT-BUKRS
              I_LIFNR       = IT_ACCIT-LIFNR
              I_WAERS       = IT_ACCCR-WAERS
              I_BLDAT       = IT_ACCIT-BLDAT
              I_XBLNR       = IT_ACCIT-XBLNR
              I_WRBTR       = IT_ACCCR-WRBTR
              I_KOART       = 'K'
              I_REPRF       = _REPRF
              I_SHKZG       = IT_ACCIT-SHKZG
              I_XUMSW       = IT_ACCIT-XUMSW
              I_BSTAT       = IT_ACCIT-BSTAT
              I_BLART       = IT_ACCIT-BLART
         EXCEPTIONS
              MISSING_DATA  = 1
              ERROR_MESSAGE = 2
              OTHERS        = 3.

    IF SY-SUBRC &amp;lt;&amp;gt; 0.
      CALL FUNCTION 'BALW_BAPIRETURN_GET2'
           EXPORTING
                TYPE   = SY-MSGTY
                CL     = SY-MSGID
                NUMBER = SY-MSGNO
                PAR1   = SY-MSGV1
                PAR2   = SY-MSGV2
                PAR3   = SY-MSGV3
                PAR4   = SY-MSGV4
           IMPORTING
                RETURN = RETURN.
      APPEND RETURN.
    ENDIF.

  ENDLOOP.

ENDFUNCTION.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Sep 2009 16:47:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110480#M1362074</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-03T16:47:43Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110481#M1362075</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Max,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot for your reply. I appreciate your help. Actually, I am new to ABAP. So, could you please explain me of what to do in more detail. Can I insert the code into the my Webdynpro application so that my the duplicate entry check would be done??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am sorry if I am causing any inconvenience. I appreciate your help and support.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 08:05:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110481#M1362075</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T08:05:45Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110482#M1362076</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi srinivas, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks  for your reply. I did check the return table and it doesn't show any warning messages as well!!! I haven't got a clue of what to do in this situation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 08:07:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110482#M1362076</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T08:07:45Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110483#M1362077</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I suppose your Webdynpro just calls the BAPI, so u need any modification here, but only place the control inside the BAPI.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Let me know which tool u prefer to use:&lt;/P&gt;&lt;P&gt;BTE or BADI?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 08:11:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110483#M1362077</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T08:11:46Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110484#M1362078</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Max,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I prefer the easiest way of doing this as I am a bit new to ABAP. I hope you can understand my situation!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 08:13:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110484#M1362078</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T08:13:40Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110485#M1362079</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Start with following steps&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Run trx SE19&lt;/P&gt;&lt;P&gt;- Insert ACC_DOCUMENT in CLASSIC BADI section&lt;/P&gt;&lt;P&gt;- Press Create Impl.&lt;/P&gt;&lt;P&gt;- Insert Z_ACC_DOCUMENT as implementation name&lt;/P&gt;&lt;P&gt;- Press Enter&lt;/P&gt;&lt;P&gt;- Insert a short text in your implementation&lt;/P&gt;&lt;P&gt;- Add BKPFF as filter&lt;/P&gt;&lt;P&gt;- Active it&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 08:33:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110485#M1362079</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T08:33:51Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110486#M1362080</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Max,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did what you said. What should I do next?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 08:51:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110486#M1362080</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T08:51:35Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110487#M1362081</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After activing the BADI the system should migrate it to the new BADI&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you done it?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 09:06:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110487#M1362081</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T09:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110488#M1362082</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Max,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, I think I did the migration. Because I can see the field "Impl migrates to enhancement  --Z_ACC_DOCUMENT" in the present screen. What should I do next?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 09:09:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110488#M1362082</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T09:09:21Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110489#M1362083</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now u need to implement the method CHANGE, so back to the BADI and press INTERFACE tab and double click on method CHANGE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here u need to insert the code to check the duplicate posting&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: W_ACCIT  TYPE ACCIT.
  DATA: _REPRF   TYPE LFB1-REPRF.
  DATA: W_ACCCR  TYPE ACCCR.
  DATA: W_RETURN TYPE BAPIRET2.



  LOOP AT C_ACCIT INTO W_ACCIT WHERE KOART = 'K'.
* Check if the vendor has to be available for duplicete posting control
    SELECT SINGLE REPRF FROM LFB1 INTO _REPRF
       WHERE LIFNR = W_ACCIT-LIFNR
         AND BUKRS = W_ACCIT-BUKRS.
    IF SY-SUBRC &amp;lt;&amp;gt; 0.
      CLEAR _REPRF.
    ENDIF.

    READ TABLE C_ACCCR INTO W_ACCCR WITH KEY POSNR = W_ACCIT-POSNR.

    CALL FUNCTION 'FI_DUPLICATE_INVOICE_CHECK'
      EXPORTING
        I_BUKRS       = W_ACCIT-BUKRS
        I_LIFNR       = W_ACCIT-LIFNR
        I_WAERS       = W_ACCCR-WAERS
        I_BLDAT       = W_ACCIT-BLDAT
        I_XBLNR       = W_ACCIT-XBLNR
        I_WRBTR       = W_ACCCR-WRBTR
        I_KOART       = 'K'
        I_REPRF       = _REPRF
        I_SHKZG       = W_ACCIT-SHKZG
        I_XUMSW       = W_ACCIT-XUMSW
        I_BSTAT       = W_ACCIT-BSTAT
        I_BLART       = W_ACCIT-BLART
      EXCEPTIONS
        MISSING_DATA  = 1
        ERROR_MESSAGE = 2
        OTHERS        = 3.

    IF SY-SUBRC &amp;lt;&amp;gt; 0.
      CALL FUNCTION 'BALW_BAPIRETURN_GET2'
        EXPORTING
          TYPE   = SY-MSGTY
          CL     = SY-MSGID
          NUMBER = SY-MSGNO
          PAR1   = SY-MSGV1
          PAR2   = SY-MSGV2
          PAR3   = SY-MSGV3
          PAR4   = SY-MSGV4
        IMPORTING
          RETURN = W_RETURN.
      APPEND W_RETURN TO C_RETURN.
    ENDIF.

  ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 09:21:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110489#M1362083</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T09:21:39Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_ACC_DOCUMENT_POST posting duplicate entries</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110490#M1362084</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Max,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did insert the code in the "Change" method and activated the method as well. What should I do next? Sorry for asking you every step. Your help is very much appreciated!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Gopal.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Gopal on Sep 4, 2009 11:25 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Sep 2009 09:25:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-acc-document-post-posting-duplicate-entries/m-p/6110490#M1362084</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-04T09:25:40Z</dc:date>
    </item>
  </channel>
</rss>

