Have you ever asked the following question: Do you charge interest on overdue receivables? Was the reply that you received similar to this response: Not always, but we want the ability to do so at any given time. With some behind-the-scenes configuration across a few areas of the FI modules within SAP ERP and some process management, you can address this requirement.
Key Concept
Users of SAP ERP applications use sets for various tasks. Account groups, cost center groups, and financial statement versions are all types of sets within the SAP ERP system. A basic set of day-to-day transaction codes relevant for future interest calculation can be configured on a transaction code table. The set can then be added to the substitution configuration Boolean logic that is used to block interest calculation on accounts receivable-related transactions. This set makes future maintenance of the relevant transaction codes easy because you don’t have to revise the substitution configuration every time a transaction change is required to be added or deleted for the interest calculation process. Instead, all you need to do is change the set.
Interest calculation on overdue receivables has become more prevalent in the consumer products and distribution industries in these times of tighter credit and increased emphasis on timely cash collections. In my experience, some, but not all customers were subject to interest on their overdue invoices. Given this requirement, I developed the solution on which this article is based.
The method for calculating interest on overdue receivables spans a few areas of the Financials space within the SAP ERP system, ranging from the somewhat technical to straightforward accounting. The technical understanding ranges from semicomplex Boolean logic within FI substitution configuration to the execution of the interest calculation on the end user side. Now I explain the following steps to configure and execute this process:
- Build a prerequisite for a substitution configuration that you execute to make the interest block indicator available for substitution.
- Create a basic set of transaction codes that are the result of accounts receivable (FI-AR) transaction postings
- Configure the Financial Accounting Line Item substitution to block interest calculation on FI-AR-related transactions
- Run program RGUGBR00 with transaction SA38 to generate the substitution
- Execute transaction OB32 to allow the interest block to be changed on FI documents
- Configure the interest calculation
- Define the number range for the interest form stored in the Reference field of the financial document that is created from the interest calculation
- Prepare the calculation for item interest
- Define the reference interest rate
- Define time-based terms to attach an effective date to an interest rate
- Enter actual interest values into the reference interest rates
- Prepare the interest posting configuration
- Assign forms to the interest indicators for customer-facing correspondence
- Populate the interest indicator in the company code view of the customer master
- Examine a customer account snapshot with a custom SAP List Viewer (ALV) to analyze a customer account for the purposes of selective interest calculation
- Execute the interest calculation
Step 1. Build a prerequisite for a substitution configuration that you execute in step 3 to make the interest block indicator available for substitution. The interest block indicator is set in the line item of a customer document to prevent the customer document from being selected for interest calculation. The substitution configuration activates the interest block indicator for all customer documents as they are posted in this example.
Execute transaction SM30 in the command bar with view VWTYGB01 as shown in Figure 1 and click the Maintain button. Table VWTYGB01 is titled Maintenance View for GB01, which is not very intuitive. (In SAP technical terms, GB01 means classes for Boolean formulas.) Deselect the exempted from interest calculation field (BSEG-ZINKZ) by unchecking the Exclude check box (Figure 2). This step makes this field substitutable in step 3. You activate the interest block indicator for all FI-AR-related documents via an FI substitution in this example. This action allows the users to go in at a later time during customer account analysis to unblock selected invoices that they wish to be included in the interest calculation run, thereby facilitating an ad hoc interest calculation process.

Figure 1
Maintenance of view VWTYGB01

Figure 2
Maintenance of the exempted from interest calculation field by unchecking the Exclude check box
Configuring a field as substitutable was previously done with a program that came from SAP Note 42615. Not all the fields are substitutable within the standard FI substitution configuration as installed. Choose your substitutable fields wisely from a data integrity and performance perspective. That is, avoid substituting dimensions that the SAP system already populates via its source code or standard configuration processes unless absolutely necessary.
Step 2. Create a basic set of transaction codes that result in an FI-AR invoice posting. These day-to-day transaction codes are relevant for future interest calculation. This set, which is configured on a transaction code table, is added to the substitution configuration Boolean logic that is covered in step 3. Maintaining this set facilitates future maintenance of the relevant transaction codes because you don’t have to go into the substitution configuration every time a transaction is required to be added or deleted for the interest calculation process. A simple set change solves the issue.
Sets are used extensively throughout SAP ERP applications. Account Groups, Cost Center Groups, and Financial Statement Versions are all types of sets within the system. In this case you use a set as a group reference in Boolean logic. For more information, go to https://help.sap.com and execute a keyword search on sets.
Use transaction code GS01 or follow IMG menu path Accounting > Financial Accounting > Special Purpose Ledger > Information Systems > Define Libraries. Then from the menu bar select Report Writer > Set > Create. Create a basic set on table SYST with transaction GS01, as shown in Figure 3.

Figure 3
The initial screen for creating a Report Writer set
The set that you create in Figure 3 contains all the relevant transaction codes that result in an FI-AR invoice posting (Table 1).

Table 1
FI-AR-related transaction codes
Click the enter icon
, populate the transactions from Table 1 as shown in Figure 4, and click the save icon
. The SYST table is titled ABAP System Fields. This table contains many technical objects for potential use in the substitution logic. In this case use the TCODE (transaction code) field. Reference this table via the set that you create in the substitution configuration in step 3.

Figure 4
Create a basic set of transaction codes
Step 3. Configure the Financial Accounting Line Item substitution to block interest calculation on FI-AR-related transactions. Use transaction code OBBH or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Incoming Invoices/Credit Memos > Make and Check Document Settings > Substitution in Accounting Documents. Click the New entries button (Figure 5). This action brings you to the screen in Figure 6. Enter a company code in the CoCd column and 2 in the CallPnt column. The call-up point (CallPnt) signifies that you are substituting at the line item.

Figure 5
The initial screen of the FI substitution

Figure 6
The initial line item substitution screen
Populate an activation level (Activtn level) of 1, which means active (Figure 6). Setting the substitution to active in this spot in the configuration does not cause the substitution to function. You need to run an activation program later to fully activate the substitution. Now double-click anywhere in the line that you just created in Figure 6 and click the Yes button at the dialog box. The system normally asks whether you want to create the substitution. After you select Yes, the screen in Figure 7 appears.

Figure 7
Configure the interest block field as substitutable
Click the Step button to bring up a pop-up to set the substitutable field in accounting documents (Figure 7). In this case choose the ZINKZ interest block field that you configured as substitutable in step 1. Click the enter icon to complete this step.
Now set the value of your substitution. Click the Substitutions node on the left side of the screen in Figure 8 to set the substitution constant value for the Interest Block check box. In this case you populate it with an X. The Interest Block field is nonvalidated (i.e., SAP does not check the field against tables of allowed values), so any value in the field suffices.

Figure 8
Set the substitution value
To set up the substitution prerequisite configuration, double-click the Prerequisite node in the screen in Figure 8 and choose Settings > Expert mode from the menu bar. This way, you can enter the syntax as shown in Figure 9. (Note: The syntax is for the ZBARTRANSACTION set that was created in Step 2.)

Figure 9
Boolean logic for substitution prerequisite configuration
Note the IN logic that calls the Report Writer set from step 2. This logic is similar to that of a SQL statement, so a little programming knowledge here is helpful. The Account Type is called from the Structure BSEG - Accounting Document Segment. The aforementioned logic is relatively straightforward, but the substitution functionality is almost limitless with potential table-field combinations and programming with user exits. Click the save icon and then the exit arrow icon
to return to the screen in Figure 5.
Step 4. Run program RGUGBR00 with transaction SA38 to generate the substitution. Use transaction code SA38 or follow the menu path System > Services > Reporting. Enter RGUGBROO in the Program field (Figure 10) and click the execute icon
.

Figure 10
The initial screen of substitution activation configuration
Populate the screen as shown in Figure 11 and click the execute icon. To signal the completion of this step, the following message appears at the bottom of the screen: Save and generation successfully completed.

Figrue 11
The substitution activation program
Step 5. Execute transaction OB32 to allow the interest block to be changed on FI documents. This step is important because the interest block needs to be removed from the FI-AR document to process a selective or ad hoc interest calculation (Figure 12). Use transaction OB32 or follow IMG menu path Financial Accounting (New) > Financial Accounting Global Settings (New) > Document > Rules for Changing Documents > Document Change Rules, Line Item. Select the Field Can Be Changed check box and click the save icon.

Figure 12
Set the interest block field to changeable
Step 6. Configure the interest calculation. First, define the interest indicator. The interest indicator is a configured field entry that is the highest level of configuration for interest calculation. It is stored in the company code data of the customer master so that interest calculation can be processed. Individual item interest calculation and balance interest calculation are available methods of interest calculation. In this example you configure item interest calculation.
Use transaction OB46 or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation Global Settings > Define Interest Calculation Types. Add an Interest ID, description in the Name field, and a P in the Interest Calculation Type (Figure 13). After you click the enter icon, the Item Interest calculation in the second Name field defaults.

Figure 13
Configure the interest calculation type
Step 7. Define the number range for the interest form that is stored in the Reference field of the financial document created from the interest calculation. A form is the means by which the SAP system formats customer-facing documents such as demand letters or accounts statements. This step is optional if you desire a unique number range that is assigned to an SAP form printout.
Use transaction code FBN1 or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation Global Settings > Define Number Ranges for Interest Forms. Then enter the relevant company code and click the change Intervals button (Figure 14).

Figure 14
The initial number range configuration screen
Add a new number range by clicking the Interval button
and then click the save icon (Figure 15). You can populate this unique number range in the output control screen in the Output Control section in Figure 16.

Figure 15
Interest form number ranges

Figure 16
The item interest calculation output control screen
Step 8. Prepare the calculation for item interest. Execute the item interest configuration that references the interest indicator that you created in step 6. This step is quite involved.
Follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation Global Settings > Prepare Item Interest Calculation (Figure 17). Find the 91 interest indicator that should have been automatically populated from step 6 and double-click that entry.

Double-clicking yields a very large and detailed configuration screen. Navigate to the screens shown in Figures 18 through 20 by scrolling. In the Item Selection section select the Open Items check box to calculate interest on invoices that are still open (Figure 18). Select the No Cleared Items radio button to ensure that cleared items are not selected for interest calculation.

Figure 18
Item selection configuration
Now configure the interest determination. For this example, populate or choose the following key fields (Figure 19):
- Ref. Date. This file is for the baseline date (i.e., the starting point from which the number of days due is calculated).
- Calendar type. Bank calendar (B) is the default entry.
- Tolerance days. You can leave this field blank. Typically, a few grace days are given in practice. In the example, the field is 5.
- Only calculate interest on debit items. Selecting this option means that account credits do not have interest calculated on them.

Figure 19
Interest determination
In this stage you decide whether to generate an actual invoice for interest calculation (Figure 20). Select the Post interest check box to generate an FI document when you calculate interest. In some cases, only a demand letter is required from interest calculation given that certain organizations deem interest charge invoices as impossible to collect.

Figure 20
Posting determination
In the Terms of Payment field enter the appropriate term. Most interest invoices are due immediately. Select the Posting with Invoice Ref. option. Selecting this indicator references the original invoice from which the interest is to be calculated. Select the Transfer of Account Assignment Info option to transfer any account assignments from the original invoice document. Click the save icon when you are done.
Step 9. Define the reference interest rate. The reference interest rate contains a valid from date that is later coupled with the interest indicator from step 6. You configure the actual interest rate in step 11. Use transaction OBAC or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation > Define Reference Interest Rates. Enter Long text and a Description (Figure 21).

Figure 21
The initial screen for the reference interest rate configuration
The date from is the effective date of the calculation. To keep the interest execution programs from returning error messages, ensure that items to be charged interest do not fall before the date entered in the Date from field (Figure 21).
Step 10. Define time-based terms to attach an effective date to an interest rate. Use transaction OB81 or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation > Define Time-Based Terms. The reference interest rate is from step 9, and the interest indicator is from step 6. Populate the Premium field if an additional interest rate is to be charged (Figure 22). The Amount from field is the minimum amount of selection for the interest charge.

Figure 22
Attach an effective date for interest indicator
Note
You can graduate interest by repeating step 10 to add new entries to the configuration in Figure 22 and increasing the Sequential number key by 10, for example. An increasing Sequential number key adds logical steps that the interest calculation program follows when this configuration is accessed by the source code.
Step 11. Enter actual interest values into the reference interest rates from step 9. Use transaction code OB83 or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation > Enter Interest Values. In this case the interest rate (Int. Rate) is 12 percent (Figure 23).

Figure 23
The reference interest rate from previous configuration with interest rate attached
Step 12. Configure the interest posting. At this stage, the company codes, G/L, and customer accounts are integrated with the interest indicator for postings. The business transactions are shipped with the SAP ERP system and do not need to be changed. Use transaction code OBV1 or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation > Interest Posting > A/R: Calculation of Interest on Arrears. You do not need to change anything in Figure 24.

Figure 24
The initial configuration screen for interest posting
Click the create icon
to add company code information (Figure 25). Enter 1000 in the Business transaction field for the interest received business transaction. Populate the Company code field, enter the interest indicator from step 6 in the Interest indicator field, and enter a plus sign (+) in the Business area field. This step decreases the selection to the company code and interest indicator level.

Figure 25
Enter business transaction and company code information
Click the enter icon to go to the screen shown in Figure 26. Enter 01 in the Posting Key field for the debit to a customer receivable account and 1000 in the Account symbol field. In the credit section enter 50 in the Posting Key field and 0001 in the Account symbol field.

Figure 26
The debit is assigned to a customer posting key for the receivable and the credit to the G/L for the income or liability posting
Click the Accounts button in Figure 24 and populate the chart of accounts as shown in Figure 27. Click the enter icon.

Figure 27
Enter your chart of accounts at the prompt
Populate a general ledger account (typically a liability) in the first line and the masking in the second line as shown in Figure 28. Masking is SAP’s means of selecting field values. The plus (+) character acts like a programming wild card in its selection behavior. The more plus signs that are present, the more open the selection. For example, a +1++++++++ masking selects all accounts that have a 1 in their second position. The masking facilitates proper execution of the interest receivable posting.

Figure 28
Enter a G/L account for interest posting on the G/L as well as the masking
Step 13. Assign forms to the interest indicators for customer-facing correspondence. The output can be in the form of paper, email, or a PDF. Use transaction OB84 or follow IMG menu path Financial Accounting (New) > Accounts Receivable and Accounts Payable > Business Transactions > Interest Calculation > Interest Calculation > Print > Assign Forms for Interest Indicators.
Enter the 91 interest indicator from step 6, your company code, and the form F_DUZI_01. This form arranges information on customer-facing output and can be customized to your needs via SAP’s form configuration (Figure 29). Click the save icon to complete this step.

Figure 29
The reference interest indicator from step 6
Step 14. Populate the interest indicator 91 from step 6 in the company code view of the customer master. Then process the interest calculation. Follow the menu path Accounting > Financial Accounting > Accounts Receivable > Master Records > FD01 - Create. Populate the interest indicator in the interest calculation section as shown in Figure 30. Populating the interest indicator automatically displays the interest block indicator in all documents related to this customer upon posting.

Figure 30
Enter the interest indicator
Step 15. Examine a customer account snapshot with a custom ALV to analyze a customer account for the purposes of selective interest calculation. Follow the menu Accounting > Financial Accounting > Accounts Receivable > Account > FBL5N - Display/Change Line Items (Figure 31).

Figure 32
Analyze a customer account for selective interest calculation
Note
In Figure 31, I used the ALV to add the days in arrears by net due date field (displayed as Arrear) to the layout to assist in the analysis for interest calculation selection.
Double-click a document in the ALV display from Figure 31. Double-click the customer line item and a pop-up screen appears (Figure 32). When you double-click document 1800000001, interest is blocked in the invoice courtesy of the substitution configuration.

Figure 32
Blocking interest in an invoice
Now remove the X in the Int.Block field (Figure 33) and click the enter icon.

Figure 33
Remove the interest block on selected documents
Step 16. Execute the interest calculation. Use transaction code FINT or follow menu path Accounting > Financial Accounting > Accounts Receivable > Periodic Processing > Interest Calculation > Item Interest Calculation > FINT - Item Interest Calculation (Figure 34). Populate your customer number, company code, and a date for interest calculation. Click the execute icon.

Figure 34
Calculate item interest
The output is displayed in Figure 35 and shows the interest calculation. Notice that more than one invoice was selected for interest calculation given that the interest block was removed on multiple documents.

Figure 35
View results
By using some creative thinking across multiple standard functions within SAP ERP, you can deliver an efficient interest calculation process, thereby avoiding costly and maintenance-intensive programming.
Justin Gurski
Justin Gurski has more than 17 years of experience implementing SAP solutions in the finance, controlling, and business intelligence areas. Prior to becoming an SAP consultant, Justin worked within various industries in finance, cost accounting operations, and system areas with increasing responsibility. He holds a CPA license, a BBA in accounting and management sciences, and an MBA in strategy and information systems.
If you have comments about this article or publication, or would like to submit an article idea, please contact the editor.