Lockbox is the most popular way to handle the receipt and processing of incoming payments in the United States. This service is offered by all major banks. A company can create n number of such accounts at its bank (or banks), which will work as its payment collection partner for customer payments. The customers, then, send their payments to these bank (lockbox) accounts, along with that they provide remittance information for what open items these customer payments intend to clear. Now once the bank has received all these payments for a day, it creates an electronic data file from the payment advice data and the customer payment amounts, for transmission to the Lockbox owner (company). Once the company receives the file (or fetches it from Bank sFTP), it uploads these file(s) in SAP which in turn automatically clears customer open items and posts accounting entries based on the configuration setup.
This sounds familiar to most of us, right? But before starting the blog it was necessary to give an overview of what the lockbox functionality is all about. So now as we understand it correctly, let’s deep dive into this functionality. Firstly, the file structure which the bank sends – BAI2 file. Now I am not going to discuss about BAI file, which is a cheaper option than BAI2, but with this file you may not have a suitable ‘hit rate’ for automatically matching payments to customer open items. Therefore, BAI2 is the recommended one for processing large volume of Lockbox payment transmissions each day. It considers common scenarios such as multiple items are paid per single check and deductions occur commonly etc.
Please Note: banks charge per keystroke, therefore the BAI2 files will cost more to produce than BAI files.
You can get the BAI2 file sample from the SAP program = RFEBLBT2
An extract from my system:
Put your cursor somewhere on the data –
Now in case you are new to the BAI2 file structure, you can always check these field structures in the system in following SAP structures (T-code SE11 > View):
This record type This record type marks the beginning of the data and identifies both the source and destination of all data contained therein. It comes only once per lockbox within the file, unless your transmission contains four lockboxes, for instance, then you will have four of this record ‘1’ in your file.
This record type identifies the purpose, content and physical characteristics of the data. It is not a mandatory record for lockbox processing. Some banks utilize a Record 2, and others don’t. Similar to record 1, there can be only one record 2 per lockbox within the file, unless there are many lockbox transmissions within a single file.
This record is used to reduce the size of ensuing detail records by carrying the required information that is common to all the detail records it precedes for a given deposit site. Like record 1, there can be only one record 5 per lockbox within the file, unless there are many lockbox transmissions within a single file.
This record type contains remitter’s bank information (Transit Routing No. and Account Number), commonly known as the “MICR” data (Magnetic Ink Character Recognition). This is the data that appears at the bottom of bank checks. This record also contains remittance amount and check information, on which the frequency of this record type is dependent, i.e. the record will appear multiple times in the file, if there is more than one check, or if there is a new customer’s information within the same batch.
This record provides a means of handling multi-invoice transactions. If a transaction contains one check multiple invoices, this record is used to accommodate this additional data. It contains the invoice numbers, payment amounts per invoice, and external reason code for the payment. Please note that only one invoice is placed into each record 4.
Tip: In the overflow record, a free text may be appended after the reason code. This text is not transferred to the payment advice position. To do so, kindly refer to note 565284, which can assist you in filling the payment advice item text (field AVIP-SGTXT) with the record 4 free text.
This record marks the end of a batch of detail records and is used for balance and control purposes. Note that each batch has a unique, identifying set of sequential batch and item numbers.
Record Type 8 appears only once in the Lockbox file. Record 8 is the “Service Total Record” which signifies the end of all Lockbox bundles.
This record marks the end of the data and includes the total number of records. There can only be one Record 9 in a file.
Tip: Please note that the total length for each record is fixed. Therefore, spacing is critical because the Lockbox program reads the file based on character position. So, use spaces to make up the excess space not used by an item within the record. For example, if your Origin of Transmission only uses 6 characters, then it should be preceded by four blank spaces.
To build different scenarios, you can recycle and edit the file. Two very important things to remember:
YYMMDDHHMM
Lockbox Configuration is not a lengthy process, if all of the following information is handy –
Once you have all this information, following are the 3 steps process to configure Lockbox –
Here you must specify your lockbox links (company code; key of the lockbox to which the customer is to pay; house bank ID; lockbox number at your house bank).
Sample data –
Path: Financial Accounting >> Bank Accounting >> Bank Accounts >> Define Lockboxes for House Banks
In this activity you store control data for the lockbox procedure. Currently, only the procedure LOCKBOX is supported. This data is needed for importing lockbox files sent by banks.
Sample data –
This sounds familiar to most of us, right? But before starting the blog it was necessary to give an overview of what the lockbox functionality is all about. So now as we understand it correctly, let’s deep dive into this functionality. Firstly, the file structure which the bank sends – BAI2 file. Now I am not going to discuss about BAI file, which is a cheaper option than BAI2, but with this file you may not have a suitable ‘hit rate’ for automatically matching payments to customer open items. Therefore, BAI2 is the recommended one for processing large volume of Lockbox payment transmissions each day. It considers common scenarios such as multiple items are paid per single check and deductions occur commonly etc.
Please Note: banks charge per keystroke, therefore the BAI2 files will cost more to produce than BAI files.
You can get the BAI2 file sample from the SAP program = RFEBLBT2
An extract from my system:
(All the images shown in this blog are not any customer specific and are for public use)
Put your cursor somewhere on the data –
- Select by CTRL+Y (it will highlight the data);
- Copy via CTRL+C and paste it into a new notepad;
- Change the check number(s) in the second or third check (because by default it comes same for all 3);
- Save the notepad file
BAI2 File Structure
Now in case you are new to the BAI2 file structure, you can always check these field structures in the system in following SAP structures (T-code SE11 > View):
Record 1: FLB01 – Header Record
This record type This record type marks the beginning of the data and identifies both the source and destination of all data contained therein. It comes only once per lockbox within the file, unless your transmission contains four lockboxes, for instance, then you will have four of this record ‘1’ in your file.
Record 2: FLB02 – Service Record
This record type identifies the purpose, content and physical characteristics of the data. It is not a mandatory record for lockbox processing. Some banks utilize a Record 2, and others don’t. Similar to record 1, there can be only one record 2 per lockbox within the file, unless there are many lockbox transmissions within a single file.
Record 5: FLB05 – Detail Header Record
This record is used to reduce the size of ensuing detail records by carrying the required information that is common to all the detail records it precedes for a given deposit site. Like record 1, there can be only one record 5 per lockbox within the file, unless there are many lockbox transmissions within a single file.
Record 6: FLB26 – Detail Record (New Check)
This record type contains remitter’s bank information (Transit Routing No. and Account Number), commonly known as the “MICR” data (Magnetic Ink Character Recognition). This is the data that appears at the bottom of bank checks. This record also contains remittance amount and check information, on which the frequency of this record type is dependent, i.e. the record will appear multiple times in the file, if there is more than one check, or if there is a new customer’s information within the same batch.
Record 4: FLB24 – Overflow Record
This record provides a means of handling multi-invoice transactions. If a transaction contains one check multiple invoices, this record is used to accommodate this additional data. It contains the invoice numbers, payment amounts per invoice, and external reason code for the payment. Please note that only one invoice is placed into each record 4.
Tip: In the overflow record, a free text may be appended after the reason code. This text is not transferred to the payment advice position. To do so, kindly refer to note 565284, which can assist you in filling the payment advice item text (field AVIP-SGTXT) with the record 4 free text.
Record 7: FLB07 – Batch Total Record
This record marks the end of a batch of detail records and is used for balance and control purposes. Note that each batch has a unique, identifying set of sequential batch and item numbers.
Record 8: FLB08 – Lockbox Total Record
Record Type 8 appears only once in the Lockbox file. Record 8 is the “Service Total Record” which signifies the end of all Lockbox bundles.
Record 9: FLB09 – Trailer Records
This record marks the end of the data and includes the total number of records. There can only be one Record 9 in a file.
Tip: Please note that the total length for each record is fixed. Therefore, spacing is critical because the Lockbox program reads the file based on character position. So, use spaces to make up the excess space not used by an item within the record. For example, if your Origin of Transmission only uses 6 characters, then it should be preceded by four blank spaces.
To build different scenarios, you can recycle and edit the file. Two very important things to remember:
- Update the date and time on the first row of the data file. If not, the program will tell you that you are uploading a duplicate file
100LOCKBOXDESLOCKBOXORI 2009090526
YYMMDDHHMM
- Update the check number. Remember, the payment advice is a function of the check number. If you duplicate the check number, the payment advice will already exist, and the system will not allow file processing.
6001001000060000088888887 87654321 010142260
Lockbox Configuration
Lockbox Configuration is not a lengthy process, if all of the following information is handy –
- Total No. of lockbox account(s) along with their House bank & Account IDs
- Which Company code has which lockbox account(s)
- Lockbox account(s) – Destination & Origin keys. [Destination is generally Bank account no. and Origin is generally routing/bank key]
- Type of G/L posting(s) i.e. One posting per check, or per lockbox, or per batch;
- G/L account number for bank / bank sub-account (Lockbox Clearing);
- G/L account number for Bank clearing (incoming payment remains in this account as an open item until it is cleared or posted on account to a customer);
Once you have all this information, following are the 3 steps process to configure Lockbox –
T-code OB10 : Define Lockboxes for House Banks
Here you must specify your lockbox links (company code; key of the lockbox to which the customer is to pay; house bank ID; lockbox number at your house bank).
Sample data –
Company Code | Lockbox | House Bank | Lockbox No |
1700 | LOCKB | BNKUS | 123456 |
Path: Financial Accounting >> Bank Accounting >> Bank Accounts >> Define Lockboxes for House Banks
T-code OBAY : Define Control Parameters
In this activity you store control data for the lockbox procedure. Currently, only the procedure LOCKBOX is supported. This data is needed for importing lockbox files sent by banks.
Sample data –
Record Format | BAI | BAI2 |
Document Number Length | 10 |