Problem in Posting a document using BAPI_ACC_DOCUMENT_POST

Hi,,
I am using the function module "BAPI_ACC_DOCUMENT_POST" to post a vendor Invoice (KR). i think the t-code to post this is FV60.when i post the document, the document number is getting generated but amount is missing  in t-code fbv3 but bseg table is getting updated properly. Can any one help the actual input to be given to create a document and tax
Regards

I have a suggestion:
Try to post this kind of document (KR) with transaction code FB01. If you can see the document correctly with FBV3 transaction, then you can use BAPI you mention.
The following function modules may be useful for calculating taxes:
CALCULATE_TAX_FROM_NET_AMOUNT
CALCULATE_TAX_FROM_GROSSAMOUNT
Regards.
Rafael Rojas.

Similar Messages

  • Problem while Posting a Document Using BAPI_ACC_DOCUMENT_POST

    Hi All,
    When i try to post my General Ledger Document using BAPI_ACC_DOCUMENT_POST, i face a situation due to the exchange rate. The field EXCH_RATE in CURRENCYAMOUNT table accepts only 5 decimals. But according to my scenario it should accept more than 5 decimals. Is there any BAPI or other way to solve this issue.
    Thanks & Regards,
    Venkatesh. R

    We restricted our entry to five decimals and solved the issue.

  • Document Splitting problem while posting asset acquisition using F-90

    Hi,
    We are using ECC 6.0 with document splitting functionality and are facing problem while posting asset acquisition using F-90.
    The transaction entry details are as below:
    Document Type - KR
    Vendor Line Item PKey - 31
    Amount - 10000
    Asset Line Item with PKey - 70, Transaction Type - 100
    Amount - 10000
    The Document Splitting Rule - 0000000012 is used and the Field Status Group for the Vendor Reconciliation Account and Asset Reconciliation account have Cost Center, Profit Center and Segment as "Optional" field.
    The Balance Sheet Item - Asset Reconciliation Account has been created as
    Secondary Cost Element - 90.
    The Profit Center and Segment field have been made mandatory and zero balancing is also set in the settings for Document Splitting.
    While posting asset acquisition using F-90, we are getting the error message - "Balancing Field "Profit Center" in line item 001 not filled"
    The first line refers to the Vendor Line item.
    Please let me know how to overcome this error.
    Regards,
    Ramanand

    Please follow the below path and do config :-
    IMG>FA>Asset Accounting>Integration with the General Ledger>Additional Account Assignment Objects>Specify Account Assignment Types for Account Assignment Objects
    here you have to put KOSTL (Cost center) for both against APC and Dep run for each Dep area.
    Thanks
    Pyare

  • Problem in posting multiple documents in FB70 through BDC...

    Hi,
       I am facing a problem while posting multiple documents from a flat file in FB70 thourgh BDC batch input by using session method. However, the session is getting terminated after posting the first document. Please clarify my problem.
    Below is a sample of the data in my flat file -
    Customer,Invoice Date,Posting Date,Amount,G/L Account,Amount in doc. Curr.
    34,03.06.2009,03.06.2009,100,211000,100
    34,03.06.2009,03.06.2009,200,211000,200
    34,03.06.2009,03.06.2009,300,211000,300
    And below is the sample code of my program.
    REPORT ZANI2_BDC_FB70
           NO STANDARD PAGE HEADING LINE-SIZE 255.
    TYPES: BEGIN OF TY_STR_FB70,
             ACCNT(20)      TYPE C,     "Customer
             BLDAT(20)      TYPE C,     "Invoice Date
             BUDAT(20)      TYPE C,     "Posting Date
             WRBTR(20)      TYPE C,     "Basic Data - Amount
             HKONT(20)      TYPE C,     "G/L Account
             ITEM_WRBTR(20) TYPE C,
             "Line Item Amount In Document Currency
           END OF TY_STR_FB70,
          BEGIN OF TY_STR_FILEDATA,
             FIELDS TYPE STRING,
          END OF TY_STR_FILEDATA.
    *   data definition
    *       Batchinputdata of single transaction
    DATA:   BDCDATA LIKE BDCDATA    OCCURS 0 WITH HEADER LINE,
    *       messages of call transaction
            MESSTAB LIKE BDCMSGCOLL OCCURS 0 WITH HEADER LINE.
    DATA: IT_STR_FILEDATA TYPE STANDARD TABLE OF TY_STR_FILEDATA,
          WA_STR_FILEDATA TYPE TY_STR_FILEDATA,
          IT_STR_FB70 TYPE STANDARD TABLE OF TY_STR_FB70,
          WA_STR_FB70 TYPE TY_STR_FB70,
          G_STR_FILENAME TYPE STRING,
          G_FLG_ERROR TYPE I,
          G_INDEX TYPE I,
          G_STR_INDEX TYPE STRING,
          G_STR_FIELDNAME TYPE STRING.
    SELECTION-SCREEN BEGIN OF BLOCK INPUT.
    PARAMETERS: P_FILE TYPE IBIPPARMS-PATH,
                P_SES  TYPE APQI-GROUPID.
    SELECTION-SCREEN END OF BLOCK INPUT.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FILE.
      CALL FUNCTION 'F4_FILENAME'
        EXPORTING
          PROGRAM_NAME  = SYST-CPROG
          DYNPRO_NUMBER = SYST-DYNNR
          FIELD_NAME    = 'P_FILE'
        IMPORTING
          FILE_NAME     = P_FILE.
    Continued in the next thread..

    ...Continued from the previous thread.
    PERFORM OPEN_GROUP.
        G_INDEX = 1.  
        LOOP AT IT_STR_FB70 INTO WA_STR_FB70.
           PERFORM BDC_DYNPRO      USING 'SAPMF05A' '1200'.
          PERFORM BDC_FIELD       USING 'RF05A-BUSCS'
                                         'R'.
         "Customer
          PERFORM BDC_FIELD       USING 'INVFO-ACCNT'
                                         WA_STR_FB70-ACCNT.  
          "Invoice Date
          PERFORM BDC_FIELD       USING 'INVFO-BLDAT'
                                        WA_STR_FB70-BLDAT.                               
          "Posting Date
          PERFORM BDC_FIELD       USING 'INVFO-BUDAT'
                                        WA_STR_FB70-BUDAT.                                
         "Basic data - Amount
          PERFORM BDC_FIELD       USING 'INVFO-WRBTR'
                                        WA_STR_FB70-WRBTR.     
          PERFORM BDC_FIELD       USING 'INVFO-WAERS'
                                        'EUR'.
          G_STR_INDEX = G_INDEX.
          IF G_INDEX < 10.
            CONCATENATE '0' G_STR_INDEX INTO G_STR_INDEX.
          ENDIF.
          CONDENSE G_STR_INDEX NO-GAPS.
          CLEAR G_STR_FIELDNAME.
          CONCATENATE  'ACGL_ITEM-WRBTR(' G_STR_INDEX ')' INTO
          G_STR_FIELDNAME.
          PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                        G_STR_FIELDNAME.
                                        "'ACGL_ITEM-WRBTR(01)'.
          "G/L Acct
          CONCATENATE  'ACGL_ITEM-HKONT(' G_STR_INDEX ')' INTO
          G_STR_FIELDNAME.
          PERFORM BDC_FIELD       USING  G_STR_FIELDNAME       
                                         WA_STR_FB70-HKONT.    
            "Amount .
          CONCATENATE  'ACGL_ITEM-WRBTR(' G_STR_INDEX ')' INTO
          G_STR_FIELDNAME.
          PERFORM BDC_FIELD       USING G_STR_FIELDNAME   
                                        WA_STR_FB70-ITEM_WRBTR.
          "PERFORM BDC_DYNPRO      USING 'SAPMF05A' '1200'.
          PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                        '=BU'.
          CLEAR WA_STR_FB70.
        ENDLOOP.
        IF G_FLG_ERROR IS INITIAL.
          PERFORM BDC_TRANSACTION USING 'FB70'.
        ENDIF.
        IF G_FLG_ERROR IS INITIAL.
          PERFORM CLOSE_GROUP.
          MESSAGE 'Session created successfully.' TYPE 'I'.
        ENDIF.
      ENDIF.
    Continued in the next thread..

  • Posting period 011 2013 is not open while posting the document using F-02 getting the error

    Hi SAP Captains,
    Pls help me here.
    While posting the document using T-code F-02 getting the error "Posting period 011 2013 is not open.
    Please help me how to do, can you provide step by step.
    Rgds..Suresh

    Hi Suresh,
    You can search google and will get number of posts on this. This will lead to duplication of similar posts on forum.
    The message says "FI posting period is closed for 11th period of 2013". In which period you are trying to post the transaction?
    If it is past, open the FI posting periods in OB52.
    BR, Srinivas Salpala

  • Post the document using f-65?

    Hi Experts,
    I know the FB01 tcode  used for Posting and F-65 used for document parking, my query is there any possible to "POST"  the document using F-65?
    Thanks
    NK

    why do you want to POST with f-65 . where there is Fb01 for post But in FB01 you can Pak the docuemnt .
    Go to docuemnt menu and click on SAVE  as completed "
    Many Thanks

  • Posting Intercompany documents using program RFBIBL00

    Hi,
    I want to know if we can post intercompany documents using program RFBIBL00(Direct Input Method).
    If this is possible, please let me know how can this be achieved as I am getting an error "Cross-company code postings not defined".
    Thanks
    Harveen.

    HI
    You need to setup the relationships between the company codes. Do this via
    OBYA transaction.
    Hope this help.
    Regards
    kishore

  • Unable to transfer post the document using BAPI "BAPI_GOODSMVT_CREATE"

    Hi Experts,
    I am unable to post the document using BAPI "BAPI_GOODSMVT_CREATE", getting error "_Sales order stock --- does not exist_"
    details are stated below:
    GM_CODE : 04, it is working fine for the scenario with same saleorder number and line item, but when i give same sale order number and different line item, then i am getting the above error.
    Example : Posting from Saleorder A with line item 100 to saleorder A with lineitem 100 its working fine, but when we are posting
                    from Saleorder A with lineitem 100 to saleorder A with line item 200 it is not working.
    Also When I trying to do with the transaction MB1B manually, it is working fine. kindly suggest me.
    Needed Urgently....
    Appreciate for you early response.
    Regards,
    Sathya.
    Edited by: Sathyanarayana Raghavendra on May 6, 2010 1:00 PM

    Hi,
    Hi Did you call Function BAPI_TRANSACTION_COMMIT' after calling the BAPI.    ?
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
        EXPORTING
          wait = c_x.
    Regards,
    Jovito.

  • Problems in Posting an Accounting Document using BAPI_ACC_DOCUMENT_POST

    Hi All,
    I am facing a problem when I try to post an accounting document using the BAPI "BAPI_ACC_DOCUMENT_POST".
    While passing data to the structure "ACCOUNTTAX", I get the errors "Required field AMT_BASE was not transferred in parameter CURRENCYAMOUNT" and "Required field TAX_CODE was not transferred in parameter ACCOUNTTAX".
    Till now I was not passing the ACCOUNTTAX structure to the BAPI and posting was happening fine.
    Any pointers / solutions in this direction will be most helpful.
    Thanks in advance.
    Regards,
    Keerthi

    Hi
      As u told earlier it was fine , so it may there is some config. change done by func. so this error is coming.
      For minimum required fields fo BAPI , u can go to SE37 and click on Function Module Documentation on Application tool bar.
    here u will find good help.
    Regards
    Sachin

  • Problem in creating an account document using BAPI_ACC_DOCUMENT_POST

    Hi Experts,
    I have a porblem while creating an account document from BAPI_ACC_DOCUMENT_POST.
    The problem is acc document is geeting posted and I am getting an document number for that bapi, but its not getting saved to data base and I am getting the following error message
    "Document 1900004327 3000 does not exist in fiscal year 2005
    Message no. F5A397
    System Response
    The required document either does not exist in the fiscal year or is still being posted.
    When the document is read, archived documents are also considered."
    Please sugggest...
    We are using ECC 6.0
    Thanks,
    Suma.

    Hi,
    this means that the posting is not open...
    try with 2008...
    or else ask ur financial consultatto check, whether the 2005 is open or not.
    u also try posting manually using FB01 with same entries u r using for this BAPI...so that u can track the error.
    Also use BAPI_TRAACTION_COMMIT after bapi post.
    check ur subsystem which u r passing for the BAPI..
    wa_general-assetsubno = '0000'. Is it 3000 or 0000
    Try using 0...
    Edited by: Sumi Vasu on May 14, 2008 8:13 AM

  • Problem while posting FI document through BAPI - Multiple Exchange Rates

    I am able to post FI document with multiple exchange rates for the same currency using FB01. But, when I try to post the same document details using BAPI_ACC_DOCUMENT_POST , it throws an error F5 701 - Inconsistent Rate for Currency XXX .
    How can we avoid this error while posting through BAPI ?
    Thanks & Regards,
    Nidhi

    Hi Nidhi,
    Value range
        The field CURR_TYPE (currency type) describes the role played by a
        currency in the SAP System.
        The currency type can take on the following values, for example:
        o   00      Transaction currency
        o   10      Company code currency
        o   20      Controlling area currency
        o   30      Group currency
        o   40      Hard currency
        o   50      Index-based currency
        o   60      Global company currency
        If an entry is not made in the field CURR_TYPE, the default value "00"
        is retained.
        If only one data record is transferred in transaction currency for each
        line item, the field CURR_TYPE does not need to be filled out. If
        several data records are transferred for each line item, the currency
        type must be entered for each record.
    If the parameter CurrencyAmount is filled with the currency fields,
    a complete document check including characteristics and value
    components of profitability analysis (CO-PA). Otherwise, the account
    assignment objects are checked.
    Check the BAPI documentation SE37.
    Regards,
    Boobalan Suburaj

  • Upload item text for FI document using BAPI_ACC_DOCUMENT_POST

    Hi,
    I need to upload FI document posting using BAPI_ACC_DOCUMENT_POST.  However item text that I received is too long and need to store at item long text.  So can we use BAPI_ACC_DOCUMENT_POST to upload long text for item text? If this possible, may I know how to do this.
    Thanks.
    Regards,
    ain

    Hi,
    You cannot pass item long text using this BAPI,  Call the function module SAVE_TEXT after successfull call of BAPI
    Call Save_Text with following parameters.
    Text_ID : 0001 (Notes)
    Text_object : DOC_ITEM (Line Item Text)
    Language : EN
    Text Name : Company code +Document NO + Fiscal Year + Line item ID
    Regards
    Vinod

  • Problem in Posting Parked Document for Asset Retirement

    Hi
    I had parked asset retirement document with document type AR. At that time fields such as Plant, Asset Retirement tick, Asset No. etc. were available and I had filled up the fields.
    Now I want to post the document with FBV0. When I check the line items the above mentioned fields are not visible. When I post the document system give following message:
    Formatting error in the field RF05A-XAABG; see next message
         Message no. 00298
    Diagnosis
         During batch input or when executing CALL TRANSACTION... USING a screen
         field was filled with an invalid input format.
    System Response
         Processing was terminated.
    Procedure
         The screen field has the technical name RF05A-XAABG . The cause of the
         error is described in the following message.
         Correct  the appropriate BDC data.
    Please suggest what is the problem and how to solve it.
    Thanks & Regards
    Shripal

    Hi Sridevi
    Thanks for the reply
    It may be possible that I had not ticked Indicator Post retirement of assets directly ?
    But the real problem is that I while trying to post the parked document this field is not available. I have alread mentioned the fields which were originally available while parking but now they are not available while posting.
    Please suggest what should be done to make these fields visible while posting. If I try to create new document these field are available. They are only not available when parked document is posted.
    Thanks & Regards
    Shripal

  • Posting the Document using BAPI

    Hi All,
             We have posted document manually using 'FB01' tranasaction.But we are unable to post document through 'BAPI_ACC_DOCUMENT_POST'.we are getting errors like ''FI/CO interface: Line item entered several times''.can anybody send me the sample code for posting document.
    Thank You,
    Anupama.

    Hi,
    In the tables passed to the BAPI : accountgl, accountreceivable, accounttax and so on - you need to use a unique item number (position number, field itemno_acc) for each item.
    There is a standard SAP report with instruction how to use that BAPI:  porgram ACC_BAPI_TEST_DOCUMENT .
    good luck

  • Validation when posting a document using T. Code FB50 or F-02

    Dear Experts
    Please let me know on how to validate when posting a Cross Company Transaction using T. Codes FB50 or F-02.  The requirement is to restrict Branches (each Branch is a Company Code in SAP) to post any Cross Company documents by selecting HO Company Code in Line Item, system has to stop the User by giving Error Message.
    We can't control this using User level Authorizations because, here the Authorization is provided to the Users to post the Transactions using T. Codes FB50 and F-02.
    To restrict this, I created a Validation as below:
    Prerequisite:
    BKPF-TCODE = 'FB50' OR BKPF-TCODE = 'F-02' AND
    BKPF-BUKRS = 'Br. Company Code' AND
    BSEG-BUKRS = 'HO Company Code'
    Check:
    FALSE
    Message:
    You Can't post Cross Company Transactions using T.Code FB50 or F-02
    And I activated the above Validation in OB28 for HO and Branch Company Codes.  But the Validation is not working properly.  Can anybody help me on how to proceed further in this regard please.

    Hi,
    I haven't tried to use a transaction code for Validation purpose. Instead, I have used document type as prerequisite and then check:
    BKPF-BUKRS = 'Br. Company Code' AND
    BSEG-BUKRS = 'HO Company Code'
    If the condition is met, it displays an error (per the message in validation) while completing the line item details on posting a document.
    Please let me know if that helps. If not, I can try to replicate your scenario and let you know if there is anything missing.
    Thanks,
    Ashish

Maybe you are looking for