Customer Account Statement and Balance Confirmation Email Program
Short answer: A custom program that prepares a customer account statement as PDF, with opening balance, period movements, open items and closing balance, and sends it in bulk to each customer's accounting email address. It lists the sending result for every customer.
- Estimated effort
- M · 4–6 working days
- System
- ECC and S/4HANA
- Tables
- 6
- Scope
- Global
- Built by
- NeKuDos Teknoloji
- Last updated
Why is the standard not enough?
FD10N shows balances on screen and FBL5N lists items; neither produces a statement to send to the customer. The standard balance confirmation programs are designed to print letters and do not send a PDF by email to the customer's accounting contact with a sending result per customer. Statements are therefore often prepared in Excel and sent one by one.
Who uses it? Accounts receivable and collections teams, accounting teams that run month-end and year-end balance confirmations.
Closest standard alternatives
Tables used
The tables the program reads and updates. ECC and S/4HANA differences are marked separately.
| Table | Role | Access | System |
|---|---|---|---|
| BSIDCustomer Open Items | Customer items posted in the period and open at period end | Read | ECC + S/4 |
| BSADCustomer Cleared Items | Items posted in the period and already cleared | Read | ECC + S/4 |
| KNA1Customer Master (General Section) | Customer name and address number | Read | ECC + S/4 |
| KNB1Customer Master (Company Code) | Accounting contact email and accounting clerk | Read | ECC + S/4 |
| ADR6E-Mail Addresses (Business Address Services) | Email address in the customer address | Read | ECC + S/4 |
| T001Company Codes | Company code name and currency | Read | ECC + S/4 |
S/4HANA notes
- BSID → I_OperationalAcctgDocItem: In S/4HANA BSID is no longer filled as a separate index table; reads work through a compatibility view of the same name. For new developments the I_OperationalAcctgDocItem CDS view is recommended.
- BSAD → I_OperationalAcctgDocItem: In S/4HANA BSAD is not filled as a separate table; it is read through a compatibility view of the same name. For new developments the I_OperationalAcctgDocItem CDS view is recommended.
BAPIs and functions used
- BAPI_AR_ACC_GETKEYDATEBALANCECustomer Account Balance at Key Date. Returns the customer balance at a key date (opening and closing)
- SO_NEW_DOCUMENT_ATT_SEND_API1SAPoffice: Send New Document with Attachments. Sends the statement by email as a PDF attachment
Selection screen parameters
| Parameter | Description | Type | Reference field | Required | Example |
|---|---|---|---|---|---|
| S_BUKRS | Company code | Range / multiple | BSID-BUKRS | Yes | 1000 |
| S_KUNNR | Customer | Range / multiple | BSID-KUNNR | No | 200118 |
| S_BUSAB | Accounting clerk | Range / multiple | KNB1-BUSAB | No | T1 |
| P_FROM | Period start | Single value | BSAD-BUDAT | Yes | 01.10.2026 |
| P_TO | Period end (balance date) | Single value | BSID-BUDAT | Yes | 31.10.2026 |
| P_TEST | Test mode (preview only, no sending) | Checkbox | — | No | X |
| P_CC | Send a copy to the accounting clerk | Checkbox | — | No | X |
| P_NZERO | Skip customers without balance and movements | Checkbox | — | No | X |
Result list columns
| # | Column | Source |
|---|---|---|
| 1 | Company code | BSID-BUKRS |
| 2 | Customer | BSID-KUNNR |
| 3 | Customer name | KNA1-NAME1 |
| 4 | ADR6-SMTP_ADDR | |
| 5 | Opening balance | Calculated BAPI_AR_ACC_GETKEYDATEBALANCE result as of P_FROM − 1 day |
| 6 | Closing balance | Calculated BAPI_AR_ACC_GETKEYDATEBALANCE result as of P_TO |
| 7 | Currency | T001-WAERS |
| 8 | Status | Calculated Sent, previewed, skipped or error |
| 9 | Message | Calculated Return message of the send function or reason for skipping |
Sample result list
| Company code | Customer | Customer name | Opening balance | Closing balance | Currency | Status | Message | |
|---|---|---|---|---|---|---|---|---|
| 1000 | 200118 | Bereket Tarım Ürünleri | [email protected] | 312,400 | 446,100 | TRY | Sent | Statement sent as PDF |
| 1000 | 200245 | Kuzey Yapı Market | [email protected] | 96,320 | 0 | TRY | Sent | Statement sent as PDF |
| 1000 | 200377 | Selin Kozmetik | 41,780 | 41,780 | TRY | Skipped | No email address in the customer master |
How does the program work?
- For the selected customers, the opening balance (one day before P_FROM) and closing balance (P_TO) are taken with BAPI_AR_ACC_GETKEYDATEBALANCE. With P_NZERO, customers without balance and movements are skipped.
- Items posted in the period are read from open (BSID) and cleared (BSAD) items, and a running balance is calculated in document-date order. Items open at P_TO are shown in a separate section with their due dates.
- The form (Smart Forms or Adobe Forms) is filled with the company name (T001-BUTXT), customer data, movements, open items and a balance confirmation text, and converted to PDF.
- The recipient comes first from the customer’s accounting contact address in the company code (KNB1-INTAD), otherwise from the default email in ADR6 through KNA1-ADRNR. Without an address the customer is listed as “Skipped”.
- In test mode a PDF preview is shown and no email is sent. In a real run the PDF is sent as an attachment with SO_NEW_DOCUMENT_ATT_SEND_API1; with P_CC the accounting clerk receives a copy. The result and message are listed for every customer.
Performance notes
Calling the balance BAPI per customer is fine for hundreds of customers; for thousands, calculate the balance from the BSID/BSAD read and send in a background job.
Features
- Test mode (check without posting) Each customer's PDF can be previewed before sending.
- Line-by-line result and error log
- Runs as a background job Can run automatically on the first working day of each month for the previous month.
- Send the result by email
Authorization objects
- F_KNA1_BUKCustomer master authorization by company code
- F_BKPF_BUKAccounting document display authorization by company code
- S_OC_SENDAuthorization to send external email from SAP
Frequently asked questions
In which language is the statement prepared?
The form is prepared in the customer's communication language; Turkish and English texts come as standard. Other languages can be added by translating the form texts.
How is the customer's confirmation received?
The reply-to address of the email is set to the accounting clerk or a shared accounting mailbox; the customer sends approval or objection there. Sent emails can also be tracked in SAP's send queue.
Can it be used for vendors as well?
Yes. The same structure can be adapted to vendors with BSIK/BSAK and the vendor balance BAPI; the adaptation adds about 2 days to the effort range.
Packages that include this solution
Customer Receivables Collection Pack
A pack that brings together four solutions a collection team needs, with one customer and company code selection: receivables aging, the customer's …
Related reports
Customer Payment Behavior and Days-to-Pay Report
A custom ALV report that uses customer invoices cleared in the selected period to calculate each customer's average days to pay, amount-weighted days …
Customer Receivables Aging Report
A custom ALV report that ages customer open items by net due date and shows down payments received and other special G/L items in the same list. …
Let us build this program for your system
Briefly describe your system and expectations. We will clarify the scope and come back with an effort and price quote.