Sorting by Type and Line No. in Sales and Purchase Postings
In Business Central 2025 Wave 2 (v27), enabling the Feature Management option that lets multiple users post item ledger and value entries at the same time also makes sales and purchase posting process lines ordered by Type and then Line No. instead of Line No. alone, reducing deadlock risk. Per Tenant Extensions that rely on the old line order may need refactoring and should be tested before upgrading.

post Dynamics 365 Business Central tales, myths, legends. And something serious.
Key points
- Legacy posting sorted by Line No. only, causing deadlocks with heavy concurrency due to inconsistent resource locking order
- Business Central 2025 Wave 2 introduces sorting by Type and Line No. when the feature flag is enabled
- The new sorting order processes lines by type (G/L Account, Item, Resource, etc.) then by Line No., improving concurrent posting
- Per Tenant Extensions relying on old Line No. ordering must be refactored and tested before upgrading
- The feature can be disabled via Feature Management to fall back to legacy posting if needed
AL objects mentioned
As named in the post. A name that matches one object page by exact type and name links to it; the others stay as named.
- codeunit 80 “Sales-Post”
- codeunit “Purchase-Post”
- table 36 “Sales Header”
- table 37 “Sales Line”
Not found in BC28-30: codeunit “Purchase-Post”.
Possibly related
No source states these links: they share an object, a model read them, or a person found the same subject.
- BC Friday Tips #56 Understand Missing Fields in Copy Documents — possibly related: both name Table 37 “Sales Line”
- BC Friday Tips #84 Why Is Your Item Missing from the Sales Line Lookup? — possibly related: both name Table 37 “Sales Line”
- Business Central 2026 release wave 1 (BC28): Run AL objects and open record references using fully qualified names (Support for namespaces and fully qualified names) — possibly related: both name Codeunit 80 “Sales-Post”
- Business Central Development Serie - Part 2b: AI for BC Development — The Knowledge Gap That Ships to Production — possibly related: both name Table 37 “Sales Line”
- Context Engineering – The Thing Almost Nobody Is Actually Talking About — possibly related: both name Codeunit 80 “Sales-Post”
- Design details - Item tracking posting structure — possibly related: names Codeunit 80 “Sales-Post”
- Dynamics 365 Business Central: Add a Scan Barcode action and scan multiple/Continious scanning (Invoke barcode scanning programmatically from AL) — possibly related: both name Table 37 “Sales Line”
- Dynamics 365 Business Central: Entering Quantities/Amounts by Calculation and Negative Numbers — possibly related: both name Table 37 “Sales Line”
- Dynamics 365 Business Central: How to flow/pass custom field values from Sales Order to Production Order — possibly related: both name Table 37 “Sales Line”
- Dynamics 365 Business Central: How to note the records that the user has selected on the Subpage/Lines (Page.SetSelectionFilter in part) — possibly related: both name Table 37 “Sales Line”
Heads up
- gotcha: “already existing Per Tenant Extensions (PTE) that are relying on the old “Line No.” order” (about version 27, version 2025 Release Wave 2)
- warning: “I strongly suggest enabling the Feature Management flag in advance and widely test all your postings routines” (about version 27, version 2025 Release Wave 2)
Context
- Features: Multiple users posting item ledger entries simultaneously, Type-based sorting in sales postings, Type-based sorting in purchase postings, Legacy posting fallback, Deadlock prevention
- Versions: 2025 Wave 2 (v27), 2025 Wave 1 (v26)
Source: Duilio Tacconi, community blog. Summary, key points and quotes are derived (CONTENT-NOTICE.md); read the original for the full text.