Example: Characteristic Routine
Use
You use DataSource General Ledger: Transaction Figures (0FI_GL_1) to load data into DataStore object FIGL: Transaction Figures (0FIGL_O06).
You want to create a routine for the characteristic Debit/Credit Indicator (0FI_DBCRIND) in the target that assigns the value D to debit postings and the value C to credit postings.
-
You are in transformation maintenance. In the rule group, you double click on InfoObject Debit/Credit Indicator (0FI_DBCRIND). The rule details screen appears.
-
You choose
and add the Total Debit Postings (UMSOL) and Total Credit Postings (UMHAB) fields so that they are available in the routine. -
You choose Routine as the rule type. The routine editor opens.
-
You enter the following lines of code. They return either a D or a C as the result value:
The system checks whether the debit and credit postings contain values:
-
If the debit posting has values that are not equal to zero and the credit posting is equal to zero, the system assigns the value D.
-
If the credit posting has values that are not equal to zero and the debit posting is equal to zero, the system assigns the value C.
-
If both the debit and credit postings contain values, the system outputs an error in the monitor and terminates the load process.
-
-
You quit the routine editor.
-
In the Rule Details dialog box, choose Transfer Values.
-
You save the transformation.