Order to cash journal entry flow

Dear Members,
Please let me know the FICO entries for order to cash cycle including all the taxes applicable [exhaustive scenario]
Thanks
Sheli

Hi Sheli,
As Ajay has already stated there are no entries during sales order creation and Delivery creation, accounting entries starts from PGI which are as follows.
Goods Delivery to Customer - PGI (VL01N) 
(Outbound Delivery)                                                      
                      Dr. Cost of Goods Sold A/c     
                     Cr. Inventory A/c    
Raising of Sales Invoices (VF01)  
       Dr. Customer A/c ( Accounts Receivable)    
       Cr. Sales A/c    
       Cr. CENVAT Output Clearing A/c     
       Cr. VAT Payable A/c     
       Cr. Pro Fright O/w Claim A/c                  If any. Collecting from Customer   
       Cr. Pro Export Exp A/c                           If any. Not Collecting from Customer.    
       Dr. Freight Outward-XP A/c                   Freight Outward - XP A/c is Expense A/c    
       Cr. Pro Export Exp A/c                          If any. Not Collecting from Customer.   
       Dr. Commissn On XP Sales A/c           Commissn On XP Sales A/c is Expense A/c   
Raising of Excise Invoices (J1IIN)  
      Dr. CENVAT Output Clearing A/c     
      Cr. Excise BED Payable A/c    
      Cr. Excise ECS Payable A/c    
      Cr. Excise SHE Payable A/c    
Accounting Entry in case of Sale of Scrap (VF01)  
       Dr. Customer A/c ( Accounts Receivable)    
      Cr. Income From Scrap Sale A/c     
      Cr. CENVAT Output Clearing A/c     
      Cr. VAT Payable A/c     
      Cr. TCS - Scrap Sales     
Raising of Excise Invoices for Scrap (J1IIN)
       Dr. CENVAT Output Clearing A/c     
      Cr. Excise BED Payable A/c    
      Cr. Excise ECS Payable A/c    
      Cr. Excise SHE Payable A/c    
Receipt of Amount from Customer( F-28)  
       Dr. Bank Account A/c     
      Cr. Customer A/c ( Accounts Receivable)    
Receipt of Amount from Foreign Customer (F-28)  
       Dr. Bank Account A/c     
      Cr. Customer A/c ( Accounts Receivable)     
      Dr/Cr Exchange Fluctuation A/c    
Hope this will help you.
Regards
Eugene

Similar Messages

  • How post to park of Cash Journal entry?

    HI Gurus,
    I was park in  cash journal entry, how to post cash Journal park documents,  What t.code there in post to park cash journal entry.
    Explain detail.
    Advance Thanks & regards
    Selva

    Hi,
    If you want to give the posting date, then you have to actiate it. Go to FBCJ. Editing options> Entry Options> uncheck the Set Posting Date and Document Date to System Date.
    But beware before doing this as if you are going to post the documents in Cash journal back dated, then you cash tallying will go for a toss.
    Regards,
    Amit

  • FM for creating Cash Journal Entries

    Hi guys,
    What is the FM for making Cash Journal Entries?
    Thanks,
    Chirantan

    Hi Chirantan,
    I am sure you mean FI-CA Cash Journal, so I have listed below some of the useful FMs in CJ
    FKK_CD_PAYMENT_CREATE
    FKK_S_CASH_JOURNAL_COMMIT
    FKK_CJ_CASHDESK_OPEN_OR_CLOSE
    FKK_CJ_CHECK_BUKRS_VALIDITY
    FKK_CJ_CHECK_BVRKO_VALIDITY
    FKK_CJ_CHECK_ROLE_AKTIVITY
    FKK_CJ_CREATE_GIVEN_BACK_DATA
    FKK_CJ_CREATE_SPECIAL_TASK_DOC
    FKK_CJ_GET_DATA_FOR_PRINTING
    FKK_CJ_POST_TRANSFER
    FKK_CJ_PROHIBIT_RVRSL_OF_DOCS
    FKK_CJ_PROHIBIT_SPECIAL_DOC_70
    FKK_CJ_READ_ROLE_ACTIVITIES
    FKK_CJ_READ_SPECIAL_DOCUMENTS
    FKK_CJ_SELECT_DATA
    FKK_CJ_SET_AND_CHECK_DATA_CIC
    FKK_CJ_SHLP_OFFIC
    FKK_CJ_SHOW_ALV_TREE_DETAILS
    Best of luck,
    David

  • BAPI or Function Module for FBCJ Posting of Parked Cash Journal Entries

    Hi Experts,
    A blessed day.
    We have one requirement that requires the creation of Batch Program that will post all the outstanding (status is set in yellow) Cash Journal Entries in transaction FBCJ.
    Hereu2019s the issue, to satisfy the requirement, we either use BDC/Call Transaction OR use a Function Module/BAPI. 
    I would prefer to use Function Module/BAPI.  However, currently thereu2019s only one BAPI available for FBCJ (BAPI_CASHJOURNALDOC_CREATE).  This BAPI can only create cash journal entries BUT DO NOT change the cash journal entry for posting.  The Function Modules (Function Modules of FCJ_POST* series) cannot be used for background processing because of GUI pop-ups. These FMs also donu2019t have the Exceptions functionality for error handling and would not report the Accounting document created from the Cash Journal Entry posting.
    The problem with using BDC/Call Transaction is that it should incorporate line item selection of the cash journal entries, which I havenu2019t tried yet.  Iu2019m not sure if this is possible and if itu2019s possible, how much complexity will it incur.
    If you have the availability, would it be possible if you can help us explore on the potential solutions for this requirement?
    Thanks so much.  God bless!
    Cheers,
    ianne

    You can use RFBIBL00 program for FB01 postings. Go through the program help on how to use this program.
    This program requires a file to be on application server in a certain format.
    You may also refer the program RFBIBLT0 on how the file format should be.
    Hope this helps.
    Thanks,
    SKJ

  • Order to cash Accounting entry

    Hi
    Can you please give me the list of accounting entries that take place during order to cash flow for each event.Thanks.
    Jogendra

    Look at following site
    http://anilpassi.com/apps/demo/siva/accounting_basics/Flow_of_Accounting_Entries_in_Oracle_Applications.pdf

  • Function Module: to get Cash Journal Entries and Balances

    Dear Guru's,
    We need to develop a function module to display cash journal opening balance line item entries and closing balance of specific period.
    we have found document entries through table TCJ_DOCUMENTS or TCJ_POSITIONS now require help to generate opening and closing balances.
    Please help for the solution.
    AAR

    Hi,
    check FM FCJ_GET_DATA_FOR_SCREEN. Next time you can try to figure out by yourself. The program for transaction FBCJ is not that complicated and you can easily find this FM used there.
    Cheers

  • How to maintain petty cash dept wise cash journal entry(FBCJ)?

    Dear All,
    Cash journal fund transfer department to department (ex. Finance dept to Sales dept)
    I want maintain dept wise petty cash, how can do it explain deeply.
    *I example given one scenario
    *Com.code : (AB01) ABC LTD
    Finance dept sending Rs.10000
    Sales Dept Received amount Rs.10000
    Sales dept will do it some expenses through cash.
    I want intercompany department wise how will be maintain petty cash in sap.
    I have some solution in my mind that solution should be correct or wrong i donu2019t know suppose i done wrong correct me, Create new cash journal dept wise through, T.Code: (FBCJC0) and then we have to maintain cash journal in dept wise. Otherwise any solutions there explain detail.
    Thanks & Regards
    Selva

    Dear SAP Student
    It is just like inter unit cash transfers.  Also each department is spending cash on its own.  Now that I would like to know the balance cash departmentwise.
    As you said if I receive and pay through vendors I would be in a position to know only vendor wise balances.  It does not serve my very purpose of deparmentwise balance of cash. 
    I agree with Selva to go in for creating deparmentwise cash journals in the company code since each deparment is incurring expenses also and each department wise balance is also required. 
    Aravind

  • CASH Journal Entries

    Hi Guru's,
    Please provide me entries when we are withdrawing cash from Bank. is there any config for that.
    1. BRS How entries will be effected.
    2. In FBCJ How entries will be effected.
    Thanks and Regards,
    Nagaraju

    Hi,
    First run the transaction once by the help of Functional consultant,then by using SHDB transaction record the same as u done before now select ur recording and click Program in menu bar it will ask program name after that save it,as per transaction prepare your flat file declare internal table same order.
    Take the help of below site.
    http://www.sap-basis-abap.com/sapabap01.htm

  • Reverse Cash journal Entry

    Hi all
    My client wants to reverse  a entry in FBCJ, he has saved, posted & printed the receipt for the said entry.
    System is allowing to reverse or delete a entry which is saved & posted but when a receipt is printed for that entry it is not.
    Message is coming as Reversal failed.
    Help in this regard will be appreciated.
    Thx in Advance.
    Kamal Sankla

    it's only possible to delete/reverse CJ documents after printing a receipt if you implement modification note 359656

  • Journal Entry in Maintenance Order Settelement

    Hi Gurus,
    Can anybody tell me what is a standard journal entry flow in FI fo a maintenance order in PM to be setteled to a cost center?
    And how it is defined in the system?
    Thanks
    Sheli

    Creation of production order :Based on demand planning or during MRP run,
    Requirement will be converted into plan order based on procurement type in material
    master.
            Plan order will be converted into production order. At the time of creation of
    production order plan cost will be generated based on Bom & Routing.
          b)Goods Issue from stock to production
    FI Entry
            Dr. Raw material consumption
            Cr. Inventory
    Co Entry
              Dr .Production order
    Activities confirmation or consumed against production order, here we will confirm
    actual labour hours consumed against production order. During confirmation of activities.
    No Fi Entry
    Co Entry:
           Dr. Production order
           Cr. Cost Center
      c).Afterwards period end process :Actual activity price calculation (After
    completing the Fi period end process, Assessment and Distribution.
      d).Revaluation of order:new price applied to the production order.
        No FI Entry
    Co Entry :      
    Dr/Cr. Production order
            Cr/Dr. Cost center
    e).Actual overhead calculation It will charged to production order.
    No FI Entry
    CO Entry:
    Dr/Cr. Production order
              Cr/Dr. Cost center
    f).Goods Deliver (from production to stock)
    FI Entry:
               Dr. To stock a/c
             Cr. To factory output of production
           CO Entry:
             Cr. Production order

  • Purchase order field in Cash Journal

    Hi,
    We want to post expenses with reference to Purchase order in Cash Journal. Purchase order field is not available in the Cash Journal. How to update the purchase order field in Cash Journal.
    Regards,
    Azeem

    Hi,
    In Cash journal, there are fields which are standard from the program SAPMFCJ0 and Control FTCJ_E_POSTINGS.
    So you can see in FBCJ, while you post transaction line at the extreme right, you can see "configuration" there you can see the available fields. If you want to include, contact ABAP consultant or SAP team.
    Regards,
    Ramesh.

  • How to reverse the cash journal posted entries in FBCJ

    Hi All
    In Cash journal (FBCJ) user has posted the document by mistakenly two times, is it possible to reverse the cash journal posted document. Please advise how to reverse the posted cash journal entries.
    Regards
    K.Gunasekar

    Hi,
    For reversing, select the line and then go to "Edit > Delete Entry (Shift+F2)" or "Delete Row" button at the bottom part of screen. (Deletion function reverse the document in FBCJ)
    However in case you are trying to reverse the entry after printing a receipt if you must implement OSS Note 359656 first:-
    [https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=359656]
    Regards,
    Gaurav

  • User Exit in Cash Journal (FBCJ)

    Hi
    Does anyone knows if there are any User Exits / BADIs or other enhacements in transaction FBCJ for the Cash Journal??
    Thanks in advance
    Federico

    Afeter saving the cash journal entry with the corresponding expense, we need an extra step to authorize the expense before posting it.
    For Example
    Employee                             --> Inputs the expense in the cash journal and save it (standard functionality)
    Cash Journal Responsible   --> Aproves the expense (Non standard functionality)
    AP                                        --> Post the cash journal entry  (standard functionality)
    In order to achieve this process, we are developing a transaction in which the Cash Journal Responsible can approve the expense. That transaction will save in a Z Table the Cash Journal Document together with an approval indicator (among other fields).
    Hence, we want an enhacement so that before posting the expense, SAP validates against the Z table that the expense in the cash journal is approved. If so, it will allow to post, otherwise an error message will be issued.
    Hope this can clarify the scenario.
    Thanks for your help!
    Federico

  • Automating Cash Journal Posting using inbound proxy interface and upload program

    Hi Experts,
    I have a requirement where in cash journal posting needs to be carried out automatically by an inbound interface on a periodic basis and at the start during cut over an upload program needs to be used to upload beg balance data . For this purpose I have used BAPI_CASHJOURNALDOC_CREATE to save cash journal entries along with BAPI TRANSACTION COMMIT.
    Once the Data is successfully saved I am using FM FCJ_GET_DATA_FOR_SCREEN to get prerequisite data for the FM FCJ_POST_ALL which is used by the Standard cash journal program internally to post the saved data. ( I got this by debugging the standard transaction and both FMs are not yet released )
    The issues I am facing is that the the FM FCJ_POST_ALL does not always post the data it behaves in random fashion i.e some times it posts the entries where as sometimes it does not post the entries.
    I have tried using commit work after the FM but that also does not result in consistent behavior of the program. One more issue is the i am not allowed to use commit work in a an inbound proxy so how do i proceed ?
    I am attaching the code for further analysis:
    DATA: LIT_TCJ_TRANS_NAMES TYPE TABLE OF TCJ_TRANS_NAMES,
             LWA_TCJ_TRANS_NAMES TYPE TCJ_TRANS_NAMES,
             LV_WAIT             TYPE BAPITA-WAIT VALUE '1',
             LV_RECORD_NO        TYPE SY-TABIX.
       DATA : LIT_POSTING        TYPE STANDARD TABLE OF ISCJ_POSTINGS,
              LIT_WTAX_ITEMS     TYPE STANDARD TABLE OF TCJ_WTAX_ITEMS,
              LIT_SPLIT_POSTINGS TYPE STANDARD TABLE OF ISCJ_POSTINGS,
              LIT_CPD            TYPE STANDARD TABLE OF TCJ_CPD.
       DATA: LV_BEG_BALANCE      TYPE CJAMOUNT,
             LV_TOTAL_RECEIPTS   TYPE CJAMOUNT,
             LV_TOTAL_PAYMENTS   TYPE CJAMOUNT,
             LV_TOTAL_CHECKS     TYPE CJAMOUNT,
             LV_RUN_BALANCE      TYPE CJAMOUNT,
             LV_RUN_CASH_BALANCE TYPE CJAMOUNT,
             LV_NUMB_OF_REC      TYPE I,
             LV_NUMB_OF_PAYM     TYPE I,
             LV_NUMB_OF_CHECKS   TYPE I.
       DESCRIBE TABLE GIT_CJ LINES GV_TOTAL_RECORDS.
       SELECT MANDT COMP_CODE TRANSACT_NUMBER LANGU TRANSACT_NAME LONG_TEXT
          FROM TCJ_TRANS_NAMES
          INTO TABLE LIT_TCJ_TRANS_NAMES
          WHERE LANGU = GC_EN.
       IF SY-SUBRC <> 0.
         MESSAGE 'No Business Transaction maintained for Company Code in this client'(016) TYPE GC_I.
         LEAVE LIST-PROCESSING.
       ENDIF.
       DESCRIBE TABLE GIT_CJ LINES GV_TOTAL_RECORDS.
       LOOP AT GIT_CJ INTO GWA_CJ.
         LV_RECORD_NO = SY-TABIX.
         CLEAR: GS_HEADER_BAPI,
                GS_CJ_KEY,
                GWA_ITEMS.
         REFRESH: GIT_ITEMS,
                  GIT_RETURN.
         GS_HEADER_BAPI-COMP_CODE    = GWA_CJ-BUKRS.
         GS_HEADER_BAPI-CAJO_NUMBER  = GWA_CJ-CJNR.
         GS_HEADER_BAPI-CURRENCY     = GC_PHP.
         CLEAR LWA_TCJ_TRANS_NAMES.
         READ TABLE LIT_TCJ_TRANS_NAMES INTO LWA_TCJ_TRANS_NAMES WITH KEY COMP_CODE     = GWA_CJ-BUKRS
                                                                          LANGU         = GC_EN
                                                                          TRANSACT_NAME = GWA_CJ-BTNAM.
         IF SY-SUBRC = 0.
           GWA_ITEMS-TRANSACT_NUMBER = LWA_TCJ_TRANS_NAMES-TRANSACT_NUMBER.
           GWA_ITEMS-P_RECEIPTS        = GWA_CJ-CJRAT.
           GWA_ITEMS-TAX_CODE          = GWA_CJ-TXCOD.
           GS_HEADER_BAPI-BP_NAME      = GWA_CJ-BPNAM.
           GWA_ITEMS-POSITION_TEXT     = GWA_CJ-POTXT.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-LIFNR
             IMPORTING
               OUTPUT = GWA_ITEMS-VENDOR_NO.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-KUNNR
             IMPORTING
               OUTPUT = GWA_ITEMS-CUSTOMER.
           PERFORM SUB_DATE_FROMAT_BAPI  CHANGING  GWA_CJ-BLDAT
                                                   GS_HEADER_BAPI-DOC_DATE.
           PERFORM SUB_DATE_FROMAT_BAPI  CHANGING   GWA_CJ-BUDAT
                                                    GS_HEADER_BAPI-PSTNG_DATE.
           GS_HEADER_BAPI-REF_DOC_NO   = GWA_CJ-XBLNR.
           GS_HEADER_BAPI-ALLOC_NMBR   = GWA_CJ-ALLNO.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-KOSTL
             IMPORTING
               OUTPUT = GWA_ITEMS-COSTCENTER.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-PRCTR
             IMPORTING
               OUTPUT = GWA_ITEMS-PROFIT_CTR.
           APPEND GWA_ITEMS TO GIT_ITEMS.
           CALL FUNCTION 'BAPI_CASHJOURNALDOC_CREATE'
             EXPORTING
               HEADER              = GS_HEADER_BAPI
             IMPORTING
               COMPANY_CODE        = GS_CJ_KEY-COMP_CODE
               CASH_JOURNAL_NUMBER = GS_CJ_KEY-CAJO_NUMBER
               FISCAL_YEAR         = GS_CJ_KEY-FISC_YEAR
               CASH_JOURNAL_DOC_NO = GS_CJ_KEY-POSTING_NUMBER
             TABLES
               ITEMS               = GIT_ITEMS
               RETURN              = GIT_RETURN.
           IF GIT_RETURN IS NOT INITIAL.
             READ TABLE GIT_RETURN INTO GWA_RETURN WITH KEY TYPE = GC_E.
             IF SY-SUBRC <> 0.
               CLEAR GWA_CJ_S.
               MOVE-CORRESPONDING GS_CJ_KEY TO GWA_CJ_S.
               CLEAR GWA_RETURN.
               READ TABLE GIT_RETURN INTO GWA_RETURN WITH KEY TYPE = GC_S.
               IF SY-SUBRC = 0.
                 MOVE GWA_RETURN-MESSAGE TO GWA_CJ_S-MSG.
                 CLEAR GWA_RETURN.
                 READ TABLE GIT_RETURN INTO GWA_RETURN WITH KEY TYPE = GC_I.
                 IF SY-SUBRC = 0.
                   CLEAR GWA_CJ_E.
                   CONCATENATE GWA_RETURN-MESSAGE GWA_CJ_S-MSG INTO GWA_CJ_E-MSG SEPARATED BY GC_PIPE_FORMAT.
                   MOVE-CORRESPONDING GS_HEADER_BAPI TO GWA_CJ_E.
                   GWA_CJ_E-POSTING_NUMBER = LV_RECORD_NO.
                   APPEND GWA_CJ_E TO GIT_CJ_E.
                   GV_ERROR_RECORDS = GV_ERROR_RECORDS + GC_1.
                 ELSE.
                   IF P_TEST NE GC_X.
                     CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
                       EXPORTING
                         WAIT = LV_WAIT.
                     REFRESH:LIT_POSTING        ,
                             LIT_WTAX_ITEMS     ,
                             LIT_SPLIT_POSTINGS ,
                             LIT_CPD            .
                     CLEAR: LV_BEG_BALANCE      ,
                            LV_TOTAL_RECEIPTS   ,
                            LV_TOTAL_PAYMENTS   ,
                            LV_TOTAL_CHECKS     ,
                            LV_RUN_BALANCE      ,
                            LV_RUN_CASH_BALANCE ,
                            LV_NUMB_OF_REC      ,
                            LV_NUMB_OF_PAYM     ,
                            LV_NUMB_OF_CHECKS   .
                     CALL FUNCTION 'FCJ_GET_DATA_FOR_SCREEN'
                       EXPORTING
                         I_COMP_CODE            = GS_CJ_KEY-COMP_CODE
                         I_CAJO_NUMBER          = GS_CJ_KEY-CAJO_NUMBER
                         I_DISPLAY_PERIOD_LO    = GS_HEADER_BAPI-PSTNG_DATE
                         I_DISPLAY_PERIOD_HI    = GS_HEADER_BAPI-PSTNG_DATE
                       IMPORTING
                         E_BEGINNING_BALANCE    = LV_BEG_BALANCE
                         E_RUNNING_BALANCE      = LV_RUN_BALANCE
                         E_RUNNING_CASH_BALANCE = LV_RUN_CASH_BALANCE
                         E_TOTAL_RECEIPTS       = LV_TOTAL_RECEIPTS
                         E_TOTAL_REC_NUMBER     = LV_NUMB_OF_REC
                         E_TOTAL_PAYMENTS       = LV_TOTAL_PAYMENTS
                         E_TOTAL_PAYM_NUMBER    = LV_NUMB_OF_PAYM
                         E_TOTAL_CHECKS         = LV_TOTAL_CHECKS
                         E_TOTAL_CHECKS_NUMBER  = LV_NUMB_OF_CHECKS
                       TABLES
                         E_POSTINGS             = LIT_POSTING
                         E_WTAX_ITEMS           = LIT_WTAX_ITEMS
                         E_SPLIT_POSTINGS       = LIT_SPLIT_POSTINGS
                         E_CPD                  = LIT_CPD.
                     CALL FUNCTION 'FCJ_POST_ALL'
                       EXPORTING
                         I_COMP_CODE               = GS_CJ_KEY-COMP_CODE
                         I_CAJO_NUMBER             = GS_CJ_KEY-CAJO_NUMBER
                         I_CURRENCY                = GS_HEADER_BAPI-CURRENCY
                         I_TYP                     = 'R'
                         I_DISPLAY_PERIOD_LO       = GS_HEADER_BAPI-PSTNG_DATE
                         I_DISPLAY_PERIOD_HI       = GS_HEADER_BAPI-PSTNG_DATE
    *              IMPORTING
    *                E_ERROR_NUMBER            =
                       TABLES
                         ITCJ_POSTINGS             = LIT_POSTING
                         ITCJ_WTAX_ITEMS           = LIT_WTAX_ITEMS
                         ITCJ_SPLIT_POSTINGS       = LIT_SPLIT_POSTINGS
                         ITCJ_CPD                  = LIT_CPD
                       CHANGING
                         P_BEG_BALANCE             = LV_BEG_BALANCE
                         P_TOTAL_RECEIPTS          = LV_TOTAL_RECEIPTS
                         P_TOTAL_PAYMENTS          = LV_TOTAL_PAYMENTS
                         P_TOTAL_CHECKS            = LV_TOTAL_CHECKS
                         P_RUN_BALANCE             = LV_RUN_BALANCE
                         P_RUN_CASH_BALANCE        = LV_RUN_CASH_BALANCE
                         P_NUMB_OF_REC             = LV_NUMB_OF_REC
                         P_NUMB_OF_PAYM            = LV_NUMB_OF_PAYM
                         P_NUMB_OF_CHECKS          = LV_NUMB_OF_CHECKS.
                     COMMIT WORK.
                   ENDIF.
                   APPEND GWA_CJ_S TO GIT_CJ_S.
                   GV_SUCCESS_RECORDS = GV_SUCCESS_RECORDS + GC_1.
                   CLEAR GWA_CJ_S.
                 ENDIF.
               ENDIF.
             ELSE.
               CLEAR GWA_CJ_E.
               MOVE-CORRESPONDING GS_HEADER_BAPI TO GWA_CJ_E.
               MOVE GWA_RETURN-MESSAGE TO GWA_CJ_E-MSG.
               GWA_CJ_E-POSTING_NUMBER = LV_RECORD_NO.
               APPEND GWA_CJ_E TO GIT_CJ_E.
               GV_ERROR_RECORDS = GV_ERROR_RECORDS + GC_1.
             ENDIF.
           ENDIF.
         ELSE.
           GWA_RETURN-MESSAGE = 'Transaction Name does not correspond to any Transaction Number'(017).
           CLEAR GWA_CJ_E.
           MOVE-CORRESPONDING GS_HEADER_BAPI TO GWA_CJ_E.
           MOVE GWA_RETURN-MESSAGE TO GWA_CJ_E-MSG.
           GWA_CJ_E-POSTING_NUMBER = LV_RECORD_NO.
           APPEND GWA_CJ_E TO GIT_CJ_E.
           GV_ERROR_RECORDS = GV_ERROR_RECORDS + GC_1.
         ENDIF.
       ENDLOOP.
    ENDFORM.                    " SUB_BAPI_CALL

    Hi Experts,
    I have a requirement where in cash journal posting needs to be carried out automatically by an inbound interface on a periodic basis and at the start during cut over an upload program needs to be used to upload beg balance data . For this purpose I have used BAPI_CASHJOURNALDOC_CREATE to save cash journal entries along with BAPI TRANSACTION COMMIT.
    Once the Data is successfully saved I am using FM FCJ_GET_DATA_FOR_SCREEN to get prerequisite data for the FM FCJ_POST_ALL which is used by the Standard cash journal program internally to post the saved data. ( I got this by debugging the standard transaction and both FMs are not yet released )
    The issues I am facing is that the the FM FCJ_POST_ALL does not always post the data it behaves in random fashion i.e some times it posts the entries where as sometimes it does not post the entries.
    I have tried using commit work after the FM but that also does not result in consistent behavior of the program. One more issue is the i am not allowed to use commit work in a an inbound proxy so how do i proceed ?
    I am attaching the code for further analysis:
    DATA: LIT_TCJ_TRANS_NAMES TYPE TABLE OF TCJ_TRANS_NAMES,
             LWA_TCJ_TRANS_NAMES TYPE TCJ_TRANS_NAMES,
             LV_WAIT             TYPE BAPITA-WAIT VALUE '1',
             LV_RECORD_NO        TYPE SY-TABIX.
       DATA : LIT_POSTING        TYPE STANDARD TABLE OF ISCJ_POSTINGS,
              LIT_WTAX_ITEMS     TYPE STANDARD TABLE OF TCJ_WTAX_ITEMS,
              LIT_SPLIT_POSTINGS TYPE STANDARD TABLE OF ISCJ_POSTINGS,
              LIT_CPD            TYPE STANDARD TABLE OF TCJ_CPD.
       DATA: LV_BEG_BALANCE      TYPE CJAMOUNT,
             LV_TOTAL_RECEIPTS   TYPE CJAMOUNT,
             LV_TOTAL_PAYMENTS   TYPE CJAMOUNT,
             LV_TOTAL_CHECKS     TYPE CJAMOUNT,
             LV_RUN_BALANCE      TYPE CJAMOUNT,
             LV_RUN_CASH_BALANCE TYPE CJAMOUNT,
             LV_NUMB_OF_REC      TYPE I,
             LV_NUMB_OF_PAYM     TYPE I,
             LV_NUMB_OF_CHECKS   TYPE I.
       DESCRIBE TABLE GIT_CJ LINES GV_TOTAL_RECORDS.
       SELECT MANDT COMP_CODE TRANSACT_NUMBER LANGU TRANSACT_NAME LONG_TEXT
          FROM TCJ_TRANS_NAMES
          INTO TABLE LIT_TCJ_TRANS_NAMES
          WHERE LANGU = GC_EN.
       IF SY-SUBRC <> 0.
         MESSAGE 'No Business Transaction maintained for Company Code in this client'(016) TYPE GC_I.
         LEAVE LIST-PROCESSING.
       ENDIF.
       DESCRIBE TABLE GIT_CJ LINES GV_TOTAL_RECORDS.
       LOOP AT GIT_CJ INTO GWA_CJ.
         LV_RECORD_NO = SY-TABIX.
         CLEAR: GS_HEADER_BAPI,
                GS_CJ_KEY,
                GWA_ITEMS.
         REFRESH: GIT_ITEMS,
                  GIT_RETURN.
         GS_HEADER_BAPI-COMP_CODE    = GWA_CJ-BUKRS.
         GS_HEADER_BAPI-CAJO_NUMBER  = GWA_CJ-CJNR.
         GS_HEADER_BAPI-CURRENCY     = GC_PHP.
         CLEAR LWA_TCJ_TRANS_NAMES.
         READ TABLE LIT_TCJ_TRANS_NAMES INTO LWA_TCJ_TRANS_NAMES WITH KEY COMP_CODE     = GWA_CJ-BUKRS
                                                                          LANGU         = GC_EN
                                                                          TRANSACT_NAME = GWA_CJ-BTNAM.
         IF SY-SUBRC = 0.
           GWA_ITEMS-TRANSACT_NUMBER = LWA_TCJ_TRANS_NAMES-TRANSACT_NUMBER.
           GWA_ITEMS-P_RECEIPTS        = GWA_CJ-CJRAT.
           GWA_ITEMS-TAX_CODE          = GWA_CJ-TXCOD.
           GS_HEADER_BAPI-BP_NAME      = GWA_CJ-BPNAM.
           GWA_ITEMS-POSITION_TEXT     = GWA_CJ-POTXT.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-LIFNR
             IMPORTING
               OUTPUT = GWA_ITEMS-VENDOR_NO.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-KUNNR
             IMPORTING
               OUTPUT = GWA_ITEMS-CUSTOMER.
           PERFORM SUB_DATE_FROMAT_BAPI  CHANGING  GWA_CJ-BLDAT
                                                   GS_HEADER_BAPI-DOC_DATE.
           PERFORM SUB_DATE_FROMAT_BAPI  CHANGING   GWA_CJ-BUDAT
                                                    GS_HEADER_BAPI-PSTNG_DATE.
           GS_HEADER_BAPI-REF_DOC_NO   = GWA_CJ-XBLNR.
           GS_HEADER_BAPI-ALLOC_NMBR   = GWA_CJ-ALLNO.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-KOSTL
             IMPORTING
               OUTPUT = GWA_ITEMS-COSTCENTER.
           CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
               INPUT  = GWA_CJ-PRCTR
             IMPORTING
               OUTPUT = GWA_ITEMS-PROFIT_CTR.
           APPEND GWA_ITEMS TO GIT_ITEMS.
           CALL FUNCTION 'BAPI_CASHJOURNALDOC_CREATE'
             EXPORTING
               HEADER              = GS_HEADER_BAPI
             IMPORTING
               COMPANY_CODE        = GS_CJ_KEY-COMP_CODE
               CASH_JOURNAL_NUMBER = GS_CJ_KEY-CAJO_NUMBER
               FISCAL_YEAR         = GS_CJ_KEY-FISC_YEAR
               CASH_JOURNAL_DOC_NO = GS_CJ_KEY-POSTING_NUMBER
             TABLES
               ITEMS               = GIT_ITEMS
               RETURN              = GIT_RETURN.
           IF GIT_RETURN IS NOT INITIAL.
             READ TABLE GIT_RETURN INTO GWA_RETURN WITH KEY TYPE = GC_E.
             IF SY-SUBRC <> 0.
               CLEAR GWA_CJ_S.
               MOVE-CORRESPONDING GS_CJ_KEY TO GWA_CJ_S.
               CLEAR GWA_RETURN.
               READ TABLE GIT_RETURN INTO GWA_RETURN WITH KEY TYPE = GC_S.
               IF SY-SUBRC = 0.
                 MOVE GWA_RETURN-MESSAGE TO GWA_CJ_S-MSG.
                 CLEAR GWA_RETURN.
                 READ TABLE GIT_RETURN INTO GWA_RETURN WITH KEY TYPE = GC_I.
                 IF SY-SUBRC = 0.
                   CLEAR GWA_CJ_E.
                   CONCATENATE GWA_RETURN-MESSAGE GWA_CJ_S-MSG INTO GWA_CJ_E-MSG SEPARATED BY GC_PIPE_FORMAT.
                   MOVE-CORRESPONDING GS_HEADER_BAPI TO GWA_CJ_E.
                   GWA_CJ_E-POSTING_NUMBER = LV_RECORD_NO.
                   APPEND GWA_CJ_E TO GIT_CJ_E.
                   GV_ERROR_RECORDS = GV_ERROR_RECORDS + GC_1.
                 ELSE.
                   IF P_TEST NE GC_X.
                     CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
                       EXPORTING
                         WAIT = LV_WAIT.
                     REFRESH:LIT_POSTING        ,
                             LIT_WTAX_ITEMS     ,
                             LIT_SPLIT_POSTINGS ,
                             LIT_CPD            .
                     CLEAR: LV_BEG_BALANCE      ,
                            LV_TOTAL_RECEIPTS   ,
                            LV_TOTAL_PAYMENTS   ,
                            LV_TOTAL_CHECKS     ,
                            LV_RUN_BALANCE      ,
                            LV_RUN_CASH_BALANCE ,
                            LV_NUMB_OF_REC      ,
                            LV_NUMB_OF_PAYM     ,
                            LV_NUMB_OF_CHECKS   .
                     CALL FUNCTION 'FCJ_GET_DATA_FOR_SCREEN'
                       EXPORTING
                         I_COMP_CODE            = GS_CJ_KEY-COMP_CODE
                         I_CAJO_NUMBER          = GS_CJ_KEY-CAJO_NUMBER
                         I_DISPLAY_PERIOD_LO    = GS_HEADER_BAPI-PSTNG_DATE
                         I_DISPLAY_PERIOD_HI    = GS_HEADER_BAPI-PSTNG_DATE
                       IMPORTING
                         E_BEGINNING_BALANCE    = LV_BEG_BALANCE
                         E_RUNNING_BALANCE      = LV_RUN_BALANCE
                         E_RUNNING_CASH_BALANCE = LV_RUN_CASH_BALANCE
                         E_TOTAL_RECEIPTS       = LV_TOTAL_RECEIPTS
                         E_TOTAL_REC_NUMBER     = LV_NUMB_OF_REC
                         E_TOTAL_PAYMENTS       = LV_TOTAL_PAYMENTS
                         E_TOTAL_PAYM_NUMBER    = LV_NUMB_OF_PAYM
                         E_TOTAL_CHECKS         = LV_TOTAL_CHECKS
                         E_TOTAL_CHECKS_NUMBER  = LV_NUMB_OF_CHECKS
                       TABLES
                         E_POSTINGS             = LIT_POSTING
                         E_WTAX_ITEMS           = LIT_WTAX_ITEMS
                         E_SPLIT_POSTINGS       = LIT_SPLIT_POSTINGS
                         E_CPD                  = LIT_CPD.
                     CALL FUNCTION 'FCJ_POST_ALL'
                       EXPORTING
                         I_COMP_CODE               = GS_CJ_KEY-COMP_CODE
                         I_CAJO_NUMBER             = GS_CJ_KEY-CAJO_NUMBER
                         I_CURRENCY                = GS_HEADER_BAPI-CURRENCY
                         I_TYP                     = 'R'
                         I_DISPLAY_PERIOD_LO       = GS_HEADER_BAPI-PSTNG_DATE
                         I_DISPLAY_PERIOD_HI       = GS_HEADER_BAPI-PSTNG_DATE
    *              IMPORTING
    *                E_ERROR_NUMBER            =
                       TABLES
                         ITCJ_POSTINGS             = LIT_POSTING
                         ITCJ_WTAX_ITEMS           = LIT_WTAX_ITEMS
                         ITCJ_SPLIT_POSTINGS       = LIT_SPLIT_POSTINGS
                         ITCJ_CPD                  = LIT_CPD
                       CHANGING
                         P_BEG_BALANCE             = LV_BEG_BALANCE
                         P_TOTAL_RECEIPTS          = LV_TOTAL_RECEIPTS
                         P_TOTAL_PAYMENTS          = LV_TOTAL_PAYMENTS
                         P_TOTAL_CHECKS            = LV_TOTAL_CHECKS
                         P_RUN_BALANCE             = LV_RUN_BALANCE
                         P_RUN_CASH_BALANCE        = LV_RUN_CASH_BALANCE
                         P_NUMB_OF_REC             = LV_NUMB_OF_REC
                         P_NUMB_OF_PAYM            = LV_NUMB_OF_PAYM
                         P_NUMB_OF_CHECKS          = LV_NUMB_OF_CHECKS.
                     COMMIT WORK.
                   ENDIF.
                   APPEND GWA_CJ_S TO GIT_CJ_S.
                   GV_SUCCESS_RECORDS = GV_SUCCESS_RECORDS + GC_1.
                   CLEAR GWA_CJ_S.
                 ENDIF.
               ENDIF.
             ELSE.
               CLEAR GWA_CJ_E.
               MOVE-CORRESPONDING GS_HEADER_BAPI TO GWA_CJ_E.
               MOVE GWA_RETURN-MESSAGE TO GWA_CJ_E-MSG.
               GWA_CJ_E-POSTING_NUMBER = LV_RECORD_NO.
               APPEND GWA_CJ_E TO GIT_CJ_E.
               GV_ERROR_RECORDS = GV_ERROR_RECORDS + GC_1.
             ENDIF.
           ENDIF.
         ELSE.
           GWA_RETURN-MESSAGE = 'Transaction Name does not correspond to any Transaction Number'(017).
           CLEAR GWA_CJ_E.
           MOVE-CORRESPONDING GS_HEADER_BAPI TO GWA_CJ_E.
           MOVE GWA_RETURN-MESSAGE TO GWA_CJ_E-MSG.
           GWA_CJ_E-POSTING_NUMBER = LV_RECORD_NO.
           APPEND GWA_CJ_E TO GIT_CJ_E.
           GV_ERROR_RECORDS = GV_ERROR_RECORDS + GC_1.
         ENDIF.
       ENDLOOP.
    ENDFORM.                    " SUB_BAPI_CALL

  • Cash Journal -FBCJ

    Hi,
    Is there any table to identify the FI Document number from the Internal document number generating from the cash journal entry positing
    Gayani

    Hi
    Go to T Code : SE11
    give BKPF in database table
    Click display
    Utilities ==> Table content ==> Display
    There if field TCODE is FBCJ the those documents are from Transaction code FBCJ
    Regards
    Sunoj

Maybe you are looking for

  • How to create an event / callback in a pojo

    Let's say I want to create a class that opens and closes a JDBC connection. I'd like to create the following events: (is there a different term I should be using? Callback, Function Pointer, etc...) Event 1: Before Open Event 2: After Open Event 3. O

  • Using the Invoice Balance Due in Queries

    I am putting together a custom aging report and have hit a snag. I can not find a field name for the balance due information in the invoice, only doc total. Do I have to use a formula? If so, any suggestions? Thanks!

  • Help decoding ByteArray from file

    Hi guys, I was wondering if anybody could help me. I have a file that I am trying to parse, it is produced by an external piece of software that I have no control over, and the company that creates the software aren't been very helpful with giving me

  • How To Create the WSDL of CBP and EBF in AIA 3.0

    Hi, I have a requirement to create a CBP ( composite Business process) that will call and EBF ( Enterprise Business Flow ) in AIA. As very first step , i have to create the WSDL for both , please let me know whether i will go and manually create the

  • Keynote to Quicktime export

    I currently have keynote '09 and am having trouble producing a video that works on an HD TV. It does not seem to matter whether I use 1280x720 or 1920x1080 when I export it as a quicktime movie and specify HD the movie never plays right on the TV. It