#12696 Fix Norwegian SAF-T 1.30 debit and credit totals
Norwegian SAF-T 1.30 export now correctly calculates debit and credit totals from actual G/L entry amounts instead of stored columns, ensuring totals match exported line amounts even with reversals or negative entries.
- 5files
- 3AL files
- 2objects
Pull request · merged into main (BC30) on 2026-10-28 by AleksanderGladkov · 5 files (+248 -8), 3 AL · fix · tier official · reviewed (checked by Opus)
What changed
- Debit and credit totals in SAF-T 1.30 now calculated from G/L Amount using SQL aggregation instead of stored debit/credit columns
- Fixes discrepancies when exports contain reversals or negative entries
- Complete selection totals are repeated in every split file for consistency
- SAF-T 1.20 behavior remains unchanged
- Extensive test coverage added for reversals, negative entries, multiple journals, and split scenarios
- Behaviour changes for users or extensions.
AL objects touched
- Codeunit 10692 “Generate SAF-T 1.3 File”, NorwegianSAFT (NO layer): modified
- Codeunit 10675 “SAF-T Export Mgt.”, NorwegianSAFT (NO layer): modified
src/Apps/NO/NorwegianSAFT/app/src/Export Engine/SAFTGLEntryTotal.Query.al: added, not in the BC30 snapshot yet
Also merged into
- #12899 into
releases/29.xon 2026-10-21
Context
- Work items: AB#653928
- Labels: Team: Finance
- Systems: finance
- From the description: “Calculate debit and credit totals from positive and negative G/L Amount using SQL aggregation and the exporter’s journal filters.”
Possibly related
No source states these links: they share an object, a model read them, or a person found the same subject.
- Set Up and Export Norwegian SAF-T Files — possibly related: Documents Norwegian SAF-T file setup and export, including debit and credit calculations. (model-linked)
Source: metadata of a merged pull request in microsoft/BCApps (bcapps): title, labels, changed paths and counts, with a summary in our words. No source text and no description beyond one short quote (D10, D61).