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

BAPI for Journal Entry of G/L Revenue/Expense

Request assistance to determine which, if any, existing, SAP written, BAPI’s should be used to create G/L accounting entries for Revenues and Expenses.

We upgraded from release 3.0f to 5.0 on June 4, 2007. In our 3.0f system, we had a custom ABAP program that input (Read) an Excel generated text file for General Ledger Expense or Revenue Journal Entry transactions. There are multiple formats for this file depending upon if they are for Revenue or Expense and if they are a Reversal or not. The program then created a BDC session using either transaction FBS1, F-02, or FB01.

For version 5.0, this updated ABAP, no longer performs as required due to changes in the Profitability Segment (or PA Characteristics) area. At this point, we determined that this would be a good opportunity to upgrade the program to use BAPI’s instead of using the BDC functionality.

I have successfully coded the revised program to use BAPI:



documentheader = g_tab_acc_hdr


accountgl = g_tab_acc_acct_gl

currencyamount = g_tab_acc_curr_amt

return = g_tab_return.

To create a G/L Expense transaction. However, there are at least two requirements from our business units that the BAPI will not perform as compared to the BDC on the 3.0f system. On the old system, we could enter a Reversal Reason and Reversal Date. The above BAPI does accept the Reversal Reason but I can find no way to enter the Reversal date.

In attempting to use an SAP BAPI for a Revenue G/L transaction, I cannot find a BAPI, which will allow entry of fields for the Profitability Segment. I have reviewed as thoroughly as I can all BAPI’s and their associated structures in attempting to find even one that refers to the following fields:

t2504-ww005, " Sub delivery

ce0bt99-ww009, " Sub market

mara-matnr, " product

vbak-vkorg, " sales org

vbak-kunnr, " sold-to party

The above tables/fields are, at least in the 3.0f BDC ABAP program, those which I need to populate for the Profitability Segment.

Your assistance in determining which BAPI will fit our needs will be greatly appreciated.

Bill Fisher

BancTec, Inc.

Dallas, TX 75061


Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Oct 29, 2008 at 05:31 PM

    Hi Bill,

    Did you finally find a BAPI that allows entry in Profitability Segment?

    Thanks in advance for your response,


    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.