FI Report Custom development ALV report

G/L Line Items with Offsetting Account and Business Partner Report

Short answer: A custom ALV general ledger report that lists the line items of selected G/L accounts with debit, credit and running balance, and adds the offsetting account, the customer or vendor and the trading partner to every row. It produces one file for auditor and tax advisor requests.

Estimated effort
M · 4–6 working days
System
ECC and S/4HANA
Tables
7
Scope
Global
Built by
NeKuDos Teknoloji
Last updated

Why is the standard not enough?

FBL3N and FAGLL03 list G/L line items, but the offsetting account and the customer/vendor name from the same document are not on the row; even with extra fields only the partner on that line is filled. A running balance and separate debit/credit columns are not part of the standard layout either. For the classic ledger format auditors ask for, the data is matched document by document in Excel.

Who uses it? General ledger teams, internal and external auditors, tax advisors.

Closest standard alternatives

  • FBL3N G/L Account Line Items. Lists G/L line items; the offsetting account and the document's partner are not on the row.
  • FAGLL03 G/L Account Line Items (New). Shows new G/L line items; gives no running balance or offsetting account name.

Tables used

The tables the report reads and their join fields. ECC and S/4HANA differences are marked separately.

TableRoleJoinSystem
BKPFAccounting Document HeaderDocument header: posting date, document type, reference (driving table)—ECC + S/4
BSEGAccounting Document SegmentDocument lines: account, amount, partner, cost center, trading partnerBSEG-BUKRS = BKPF-BUKRS AND BSEG-BELNR = BKPF-BELNR AND BSEG-GJAHR = BKPF-GJAHRECC + S/4
SKATG/L Account DescriptionsG/L and offsetting account namesSKAT-KTOPL = T001-KTOPL AND SKAT-SAKNR = BSEG-HKONT AND SKAT-SPRAS = SY-LANGUECC + S/4
KNA1Customer Master (General Section)Customer nameKNA1-KUNNR = BSEG-KUNNRECC + S/4
LFA1Vendor Master (General Section)Vendor nameLFA1-LIFNR = BSEG-LIFNRECC + S/4
T001Company CodesChart of accounts and company code currencyT001-BUKRS = BKPF-BUKRSECC + S/4
ACDOCAUniversal Journal Entry Line ItemsAll line items including the offsetting account (GKONT) on S/4HANARBUKRS = BKPF-BUKRS AND BELNR = BKPF-BELNR AND GJAHR = BKPF-GJAHRS/4HANA only

Selection screen parameters

ParameterDescriptionTypeReference fieldRequiredExample
S_BUKRSCompany codeRange / multipleBKPF-BUKRSYes1000
S_HKONTG/L accountRange / multipleBSEG-HKONTYes7700000000
S_BUDATPosting dateRange / multipleBKPF-BUDATYes01.10.2026 – 31.10.2026
S_BLARTDocument typeRange / multipleBKPF-BLARTNoKR
S_KOSTLCost centerRange / multipleBSEG-KOSTLNo4110
S_PRCTRProfit centerRange / multipleBSEG-PRCTRNoPC100
P_OPENShow opening and running balanceCheckbox—NoX

Output columns

#ColumnSource
1G/L accountBSEG-HKONT
2Account nameSKAT-TXT50
3Posting dateBKPF-BUDAT
4DocumentBKPF-BELNR
5Document typeBKPF-BLART
6ReferenceBKPF-XBLNR
7TextBSEG-SGTXT
8DebitCalculated BSEG-DMBTR when SHKZG = S
9CreditCalculated BSEG-DMBTR when SHKZG = H
10Running balanceCalculated Opening balance + debit − credit (cumulative per account)
11Offsetting accountCalculated BSEG-HKONT of the opposite-side line in the same document (largest amount when several)
12Offsetting account nameCalculated SKAT-TXT50 text of the offsetting account
13PartnerCalculated BSEG-KUNNR or BSEG-LIFNR from the line or from the document's D/K line
14Partner nameCalculated KNA1-NAME1 or LFA1-NAME1
15Trading partnerBSEG-VBUND
16Cost centerBSEG-KOSTL

Sample output

G/L accountAccount namePosting dateDocumentDocument typeReferenceTextDebitCreditRunning balanceOffsetting accountOffsetting account namePartnerPartner nameTrading partnerCost center
7700000000General administrative expenses10/03/20265100004610KRKS-2026-118October office rent85,000085,0003200000000Trade payables100901Kuzey Gayrimenkul9100
7700000000General administrative expenses10/08/20265100004702KRTL-88412Cleaning service12,400097,4003200000000Trade payables100915Pırıl Tesis Hizmetleri9100
7700000000General administrative expenses10/15/20261000012233SAGroup company service fee40,0000137,4003360000000Payables to group companies20009200
7700000000General administrative expenses10/31/20261000012410SAReversal of excess accrual06,500130,900Multiple9100
A view built with fictional sample data; not real system data.

How does the report work?

  1. Document headers are read from BKPF by company code, posting date range and document type; reversals and parked documents are excluded.
  2. The BSEG lines of the documents are read; lines within the S_HKONT range become report rows.
  3. Partner: when KUNNR/LIFNR is filled on the line it is used; otherwise it is taken from the customer (KOART = D) or vendor (KOART = K) line of the same document. The name is added from KNA1/LFA1.
  4. Offsetting account: in a two-line document, the account of the other line; in a multi-line document, the account of the largest line on the opposite side, flagged as “multiple” when there are several. The account name is read from SKAT (with T001-KTOPL).
  5. The amount goes to the debit or credit column by SHKZG; the opening balance comes from the totals before the period and a running balance is calculated per account.

Performance notes

In ECC, BSEG is a cluster table; read BKPF first by date and company code, then go to BSEG with the full document key. For open-item managed accounts the BSIS/BSAS index tables are a faster entry point. On S/4HANA ACDOCA already holds the offsetting account (GKONT) and its type, so the read collapses to one table.

Features

  • ALV list (sort, filter, subtotals)
  • User-specific layout variants
  • Double-click drill-down to the document Double-clicking the document number opens FB03.
  • Export to Excel
  • Runs as a background job Large volumes such as the annual audit file are run in the background.

Authorization objects

  • F_BKPF_BUKAccounting document display authorization by company code
  • F_SKA1_BUKG/L account authorization by company code
  • F_BKPF_KOADocument authorization by account type (customer/vendor lines)

Frequently asked questions

How is the offsetting account determined in multi-line documents?

The account of the largest opposite-side line is used, and the row is flagged as "multiple" when there are several. Optionally, a view that produces one row per offsetting line can be added.

Where does the opening balance come from?

It is taken from the account totals before the period (FAGLFLEXT in the new G/L), so the running balance agrees with the G/L account balance.

Is it still needed on S/4HANA?

On S/4HANA the offsetting account is already in ACDOCA and the report is simpler to build; for the running balance, partner names and the audit layout a custom list is still preferred.

Related reports

FI Report Custom ALV report

Customer–Vendor Netting Open Items Report

A custom ALV report that puts open receivables and payables side by side for business partners that exist both as a customer and as a vendor, and …

KNA1 · LFA1 · BSID · BSIK

Let us build this report for your system

Briefly describe your system and expectations. We will clarify the scope and come back with an effort and price quote.

Related report: G/L Line Items with Offsetting Account and Business Partner Report