SAP ABAP IMG Activity FAGL_MIGSPL_RELATION (Change Document Splitting Information of Documents To Be Transferred)
Hierarchy
SAP_FIN (Software Component) SAP_FIN
   FI-GL (Application Component) General Ledger Accounting
     FAGL_MIG_CONVERSION (Package) Future Standard Reports for Building Data
IMG Activity
ID FAGL_MIGSPL_RELATION Change Document Splitting Information of Documents To Be Transferred  
Transaction Code S_AC0_52000730   (empty) 
Created on 20050311    
Customizing Attributes FAGL_MIGSPL_RELATION   BAdI 
Customizing Activity FAGL_MIGSPL_RELATION   BAdI: Define Doc. Splitting Information for Docs To Be Posted Subsequently 
Document
Document Class SIMG   Hypertext: Object Class - Class to which a document belongs.
Document Name FAGL_MIGSPL_RELATION    

Use

The documents that you would like to post to New General Ledger Accounting using migration may in some cases be split during document splitting in a way that makes little business sense.

This BAdI allows you to specify an alternative splitting result to that produced using the standard process.

You can choose one of the following options for this:

  • Line items are split on the basis of a relationship defined in the BAdI (export parameter ET_RELTAB)
  • Line items are split on the basis of the lines to be specified in the BAdI (export parameter ET_SPLITITEM)

Requirements

This BAdI is only called for migration with document splitting when the document splitting tables are built for the documents to be posted subsequently.

Standard settings

Activities

Implement the method SPLIT_ITEMS.

The method has the following parameters:

  • IS_ACCHD: Import parameter that describes the header information of the interface, enhanced by the document splitting information.
  • IT_ACCIT: Import parameter that describes the line information of the interface, enhanced by document splitting information.
  • ET_RELTAB: Export parameter.
    This table describes the relationship used to split a line.
    The line type of the internal table consists of the following parts:
    • The substructure S_POS describes the item to be split. It consists of company code, document number, fiscal year, and the number of the posting item in the accounting document. The fields Company Code. Document Number, or Fiscal Year are only filled in cross-company-code documents.
    • The substructure FAGL_S_MIG_ASGMT describes the possible account assignments for the distribution. However, the system only transfers fields that are also defined as a document splitting characteristic in document splitting.
      Field WRBTR describes an amount that itself describes the relationship of the account assignment records. The total of the amounts do not have to agree with the amount of the item to be split. The amount must not be zero.

      Splitting on the basis of the relationship occurs before distribution using the base rows.

  • ET_SPLITITEM: Export parameter.
    This table describes which lines are to be split on the basis of other lines.
    The line type consists of the following parts:
    • The substructure S_POS describes the line to be split. It consists of company code, document number, fiscal year, and the number of the posting item in the accounting document. The fields Company Code. Document Number, or Fiscal Year are only filled in cross-company-code documents.
    • The substructure B_POS describes the lines that form the basis for splitting the line described in S_POS.

      When this approach is used, internal dependencies do not apply. If the system identifies a recursion, an error message is issued.

Notes:

  • You can only use one approach for a given line.
  • Clearing lines cannot be split using these approaches.
  • The standard rule-based document splitting no longer processes the split results. However, you can use the result to split other lines.

Example

The following document in your system needs to be posted subsequently:

1    Vendor1                - 1000

2    Vendor2                - 2000

3    Expense        PC01        1200

4    Expense        PC02        800

5    Expense        PC03        1000

In terms of content, Vendor1 and the expenses in lines 3 and 4 belong together, and Vendor2 corresponds to the expense in line 5. Rule-based document splitting cannot recognize this connection and would perform the distribution for vendors on the basis of expense items so that a share in all profit centers results for each vendor. In this way, Vendor1 would be distributed on the basis of expense items 3, 4, and 5.

You do not need to fill fields BUKRS, BELNR, or GJAHR because the representation is made within a document.

  • First method: Line items are split on the basis of a relationship defined in the BAdI.
    In table ET_RELTAB, you enter a relation for the distribution to line 1 (Vendor1) and line 2 (Vendor2) for the profit centers.
    You fill table ET_RELTAB as follows:

Structure        S_POS        FAGL_S_MIG_ASGMT

Field    ...    BUZEI    ...    PRCTR ....        WRBTR

        01        PC01        120

        01        PC02        80

        02        PC03        100

  • Second method: Line items are split on the basis of the lines to be specified in the BAdI.
    In table ET_SLITITEM, you describe which lines should be used to distribute Vendor1 (line 1) and Vendor2.
    For this, you enter the following in table ET_SPLITITEM:

Structur        S_POS        B_POS

Field    ...    BUZEI    ...    BUZEI

        01        03

        01        04

        02        05

Business Attributes
ASAP Roadmap ID 152   Design data acquisition 
Mandatory / Optional 2   Optional activity 
Critical / Non-Critical 1   Critical 
Country-Dependency A   Valid for all countries 
Assigned Application Components
Documentation Object Class Documentation Object Name Current line number Application Component Application Component Name
SIMG FAGL_MIGSPL_RELATION 0 HLA0006520 Basic Functions 
Maintenance Objects
Maintenance object type E   Business Add-In - Definition 
History
Last changed by/on SAP  20050318 
SAP Release Created in 600