<?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: Error  'BAPI_ACC_DOCUMENT_POST' , in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491846#M839726</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Roberto:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I blank the fields:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; it_hdr-obj_type.&lt;/P&gt;&lt;P&gt; it_hdr-obj_key.&lt;/P&gt;&lt;P&gt; it_hdr-obj_sys.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And it_hdr-compo_acc  = 'FI', The document 0100000016 are created. When I check FB03 -&amp;gt;accounting documents, doesn't exist.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I change  hdr-compo_acc  = 'GL', this message appear:&lt;/P&gt;&lt;P&gt;"Combination of company code VEVS transaction RFBU not assigned to a ledger".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you have other idea?.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Piero Cimule.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Piero Cimule on Mar 14, 2008 9:52 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 14 Mar 2008 12:50:09 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-03-14T12:50:09Z</dc:date>
    <item>
      <title>Error  'BAPI_ACC_DOCUMENT_POST' ,</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491844#M839724</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When test the attached program, and Use 'BAPI_ACC_DOCUMENT_POST' function module the result table show ''Document are posted, without document number".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The field it_hdr-obj_type   = 'BKPFB', exist in a TTYP table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zpba_pc MESSAGE-ID m3.&lt;/P&gt;&lt;P&gt;***&lt;/P&gt;&lt;P&gt;DATA: obj_type LIKE bapiache09-obj_type,&lt;/P&gt;&lt;P&gt;      obj_key LIKE  bapiache09-obj_key,&lt;/P&gt;&lt;P&gt;      obj_sys LIKE  bapiache09-obj_sys.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: it_hdr    LIKE bapiache09,&lt;/P&gt;&lt;P&gt;      it_gl     LIKE bapiacgl09 OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;      it_curr   LIKE bapiaccr09 OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;      it_criteria LIKE bapiackec9 OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;      it_extension LIKE bapiacextc OCCURS 0 WITH HEADER LINE,&lt;/P&gt;&lt;P&gt;      t_result  LIKE bapiret2   OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: ls_zzz TYPE STANDARD TABLE OF yyy_accit WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: it_ext2 LIKE bapiparex OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;PARAMETER: hkont_1(10) DEFAULT '1440131001',&lt;/P&gt;&lt;P&gt;           hkont_2(10) DEFAULT '1440131001',&lt;/P&gt;&lt;P&gt;           ceco_1(10),&lt;/P&gt;&lt;P&gt;           ceco_2(10),&lt;/P&gt;&lt;P&gt;           cebe_1(10) DEFAULT 'VE9002',&lt;/P&gt;&lt;P&gt;           cebe_2(10).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Header Data&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;it_hdr-obj_type   = 'BKPFB'.&lt;/P&gt;&lt;P&gt;it_hdr-obj_key    = '$'.&lt;/P&gt;&lt;P&gt;SELECT SINGLE logsys INTO it_hdr-obj_sys FROM t000 WHERE mandt EQ sy-mandt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it_hdr-bus_act    = 'RFBU'.&lt;/P&gt;&lt;P&gt;it_hdr-comp_code  = 'VEVS'.&lt;/P&gt;&lt;P&gt;it_hdr-fisc_year  = '2008'.&lt;/P&gt;&lt;P&gt;it_hdr-fis_period = '02'.&lt;/P&gt;&lt;P&gt;it_hdr-doc_date   = '20080228'.&lt;/P&gt;&lt;P&gt;it_hdr-pstng_date = '20080228'.&lt;/P&gt;&lt;P&gt;it_hdr-doc_type   = 'SA'.&lt;/P&gt;&lt;P&gt;it_hdr-header_txt = 'TEXTO CAB'.&lt;/P&gt;&lt;P&gt;it_hdr-username   = 'VEJMACIAS'.&lt;/P&gt;&lt;P&gt;it_hdr-compo_acc  = 'FI'.&lt;/P&gt;&lt;P&gt;it_hdr-ref_doc_no_long = 'REFERENCIA'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;First Item&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Account number&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;it_gl-itemno_acc = '1'.&lt;/P&gt;&lt;P&gt;it_gl-gl_account = hkont_1.&lt;/P&gt;&lt;P&gt;it_gl-item_text  = 'PRUEBA TEXTO 1'.&lt;/P&gt;&lt;P&gt;it_gl-costcenter = ceco_1.&lt;/P&gt;&lt;P&gt;it_gl-profit_ctr = cebe_1.&lt;/P&gt;&lt;P&gt;APPEND it_gl. CLEAR it_gl.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Second Item&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Account number&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;it_gl-itemno_acc = '2'.&lt;/P&gt;&lt;P&gt;it_gl-gl_account = hkont_2.&lt;/P&gt;&lt;P&gt;it_gl-item_text  = 'PRUEBA TEXTO 2'.&lt;/P&gt;&lt;P&gt;it_gl-profit_ctr = cebe_2.&lt;/P&gt;&lt;P&gt;APPEND it_gl.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Set amount&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;it_curr-itemno_acc = '1'.&lt;/P&gt;&lt;P&gt;it_curr-currency = 'VEF'.&lt;/P&gt;&lt;P&gt;it_curr-amt_doccur = '100'.&lt;/P&gt;&lt;P&gt;APPEND it_curr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it_curr-itemno_acc = '2'.&lt;/P&gt;&lt;P&gt;it_curr-currency = 'VEF'.&lt;/P&gt;&lt;P&gt;it_curr-amt_doccur = '-100'.&lt;/P&gt;&lt;P&gt;APPEND it_curr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BREAK-POINT.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;check posting&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;CALL FUNCTION 'BAPI_ACC_DOCUMENT_CHECK'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    documentheader = it_hdr&lt;/P&gt;&lt;P&gt;  TABLES&lt;/P&gt;&lt;P&gt;    accountgl      = it_gl&lt;/P&gt;&lt;P&gt;    currencyamount = it_curr.&lt;/P&gt;&lt;P&gt;    return         = t_result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT t_result WHERE ( type = 'E' OR type = 'A' ).&lt;/P&gt;&lt;P&gt;  EXIT.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REFRESH t_result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_ACC_DOCUMENT_POST'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    documentheader = it_hdr&lt;/P&gt;&lt;P&gt;  IMPORTING&lt;/P&gt;&lt;P&gt;    obj_type       = obj_type&lt;/P&gt;&lt;P&gt;    obj_key        = obj_key&lt;/P&gt;&lt;P&gt;    obj_sys        = obj_sys&lt;/P&gt;&lt;P&gt;  TABLES&lt;/P&gt;&lt;P&gt;    accountgl      = it_gl&lt;/P&gt;&lt;P&gt;    currencyamount = it_curr&lt;/P&gt;&lt;P&gt;    criteria       = it_criteria&lt;/P&gt;&lt;P&gt;    extension2     = it_ext2&lt;/P&gt;&lt;P&gt;    return         = t_result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;BREAK-POINT.&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.&lt;/P&gt;&lt;P&gt;COMMIT WORK AND WAIT.&lt;/P&gt;&lt;P&gt;WRITE: obj_key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What are we do, to solve the problem?.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;P&gt;Piero Cimule.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Mar 2008 16:46:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491844#M839724</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-13T16:46:41Z</dc:date>
    </item>
    <item>
      <title>Re: Error  'BAPI_ACC_DOCUMENT_POST' ,</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491845#M839725</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;Do not fill this fields because the system it generates them&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it_hdr-obj_type = 'BKPFB'.&lt;/P&gt;&lt;P&gt;it_hdr-obj_key = '$'.&lt;/P&gt;&lt;P&gt;SELECT SINGLE logsys INTO it_hdr-obj_sys FROM t000 WHERE mandt EQ sy-mandt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and Try again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Roberto&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Mar 2008 21:30:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491845#M839725</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-13T21:30:32Z</dc:date>
    </item>
    <item>
      <title>Re: Error  'BAPI_ACC_DOCUMENT_POST' ,</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491846#M839726</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Roberto:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I blank the fields:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; it_hdr-obj_type.&lt;/P&gt;&lt;P&gt; it_hdr-obj_key.&lt;/P&gt;&lt;P&gt; it_hdr-obj_sys.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And it_hdr-compo_acc  = 'FI', The document 0100000016 are created. When I check FB03 -&amp;gt;accounting documents, doesn't exist.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I change  hdr-compo_acc  = 'GL', this message appear:&lt;/P&gt;&lt;P&gt;"Combination of company code VEVS transaction RFBU not assigned to a ledger".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you have other idea?.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Piero Cimule.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Piero Cimule on Mar 14, 2008 9:52 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Mar 2008 12:50:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-bapi-acc-document-post/m-p/3491846#M839726</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-14T12:50:09Z</dc:date>
    </item>
  </channel>
</rss>

