{"audience":"Accounts receivable and collections teams, accounting teams that run month-end and year-end balance confirmations.","authorization_objects":[{"note":"Customer master authorization by company code","object":"F_KNA1_BUK"},{"note":"Accounting document display authorization by company code","object":"F_BKPF_BUK"},{"note":"Authorization to send external email from SAP","object":"S_OC_SEND"}],"components":[],"countries":[],"effort_days_max":6,"effort_days_min":4,"effort_size":"M","faq":[{"a":"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.","q":"In which language is the statement prepared?"},{"a":"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.","q":"How is the customer's confirmation received?"},{"a":"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.","q":"Can it be used for vendors as well?"}],"features":[{"code":"test_run","label":"Test mode (check without posting)","note":"Each customer's PDF can be previewed before sending."},{"code":"log","label":"Line-by-line result and error log","note":""},{"code":"background","label":"Runs as a background job","note":"Can run automatically on the first working day of each month for the previous month."},{"code":"email","label":"Send the result by email","note":""}],"functions":[{"name":"BAPI_AR_ACC_GETKEYDATEBALANCE","role":"Returns the customer balance at a key date (opening and closing)"},{"name":"SO_NEW_DOCUMENT_ATT_SEND_API1","role":"Sends the statement by email as a PDF attachment"}],"gap":"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.","id":"fi-customer-statement-email","industries":[],"input_columns":[],"kind":"program","language":"en","lastmod":"2026-11-17","logic":"1. 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.\n2. 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.\n3. 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.\n4. 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\".\n5. 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.","module":"FI","object_type":"form","output_columns":[{"calculated":false,"formula":"","label":"Company code","source_field":"BUKRS","source_table":"BSID"},{"calculated":false,"formula":"","label":"Customer","source_field":"KUNNR","source_table":"BSID"},{"calculated":false,"formula":"","label":"Customer name","source_field":"NAME1","source_table":"KNA1"},{"calculated":false,"formula":"","label":"Email","source_field":"SMTP_ADDR","source_table":"ADR6"},{"calculated":true,"formula":"BAPI_AR_ACC_GETKEYDATEBALANCE result as of P_FROM − 1 day","label":"Opening balance","source_field":null,"source_table":null},{"calculated":true,"formula":"BAPI_AR_ACC_GETKEYDATEBALANCE result as of P_TO","label":"Closing balance","source_field":null,"source_table":null},{"calculated":false,"formula":"","label":"Currency","source_field":"WAERS","source_table":"T001"},{"calculated":true,"formula":"Sent, previewed, skipped or error","label":"Status","source_field":null,"source_table":null},{"calculated":true,"formula":"Return message of the send function or reason for skipping","label":"Message","source_field":null,"source_table":null}],"parameters":[{"example":"1000","kind":"select_option","label":"Company code","name":"S_BUKRS","ref_field":"BSID-BUKRS","required":true},{"example":"200118","kind":"select_option","label":"Customer","name":"S_KUNNR","ref_field":"BSID-KUNNR","required":false},{"example":"T1","kind":"select_option","label":"Accounting clerk","name":"S_BUSAB","ref_field":"KNB1-BUSAB","required":false},{"example":"01.10.2026","kind":"parameter","label":"Period start","name":"P_FROM","ref_field":"BSAD-BUDAT","required":true},{"example":"31.10.2026","kind":"parameter","label":"Period end (balance date)","name":"P_TO","ref_field":"BSID-BUDAT","required":true},{"example":"X","kind":"checkbox","label":"Test mode (preview only, no sending)","name":"P_TEST","ref_field":"","required":false},{"example":"X","kind":"checkbox","label":"Send a copy to the accounting clerk","name":"P_CC","ref_field":"","required":false},{"example":"X","kind":"checkbox","label":"Skip customers without balance and movements","name":"P_NZERO","ref_field":"","required":false}],"part_of":["o2c-receivables-collection-pack"],"performance":"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.","process":"O2C","quote_url":"https://nekuhub.com/en/request-a-quote/?report=fi-customer-statement-email","related":["fi-customer-payment-behavior","fi-customer-receivables-aging"],"releases":[],"source":"custom","standard_alternatives":[{"note":"Shows customer balances on screen; does not produce or send a statement.","tcode":"FD10N"},{"note":"Lists items; does not prepare a statement in a form to send to the customer.","tcode":"FBL5N"}],"summary":"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.","tables":[{"access":"read","join_on":"","role":"Customer items posted in the period and open at period end","table":"BSID","variant":"both"},{"access":"read","join_on":"BSAD-BUKRS = BSID-BUKRS AND BSAD-KUNNR = BSID-KUNNR","role":"Items posted in the period and already cleared","table":"BSAD","variant":"both"},{"access":"read","join_on":"KNA1-KUNNR = BSID-KUNNR","role":"Customer name and address number","table":"KNA1","variant":"both"},{"access":"read","join_on":"KNB1-KUNNR = BSID-KUNNR AND KNB1-BUKRS = BSID-BUKRS","role":"Accounting contact email and accounting clerk","table":"KNB1","variant":"both"},{"access":"read","join_on":"ADR6-ADDRNUMBER = KNA1-ADRNR","role":"Email address in the customer address","table":"ADR6","variant":"both"},{"access":"read","join_on":"T001-BUKRS = BSID-BUKRS","role":"Company code name and currency","table":"T001","variant":"both"}],"title":"Customer Account Statement and Balance Confirmation Email Program","url":"https://nekuhub.com/en/programs/customer-account-statement-email-program/","vendor_id":"nekudos"}