---
id: post/yzhums-com/67343
type: post
title: "Business Central 2025 wave 2 (BC27): Truncating table data with new AL method (procedure Truncate)"
summary: Business Central 2025 Wave 2 introduces the new Rec.Truncate AL method for efficiently deleting large volumes of table data in a single operation. This method improves performance over row-by-row DeleteAll operations by locking the table during the transaction, with configurable AutoIncrement behavior and delete permission checks, though it has several limitations including incompatibility with temporary tables, try functions, security filters, and tables with media fields.
tier: community
language: en
tags:
  - al methods
  - data deletion
  - performance optimization
  - table management
  - bulk operations
system: development
review:
  state: reviewed
  by: opus
  at: "2026-10-26T06:42:22.589Z"
  flags: []
generated:
  at: "2026-10-26T05:51:10.938Z"
  pipeline: 0.2.0
  prompts:
    extract-post: 1
  input_hash: d74f592b604bd3b4936ebd7de55f3a00d6697b26effbd7f812d75b58d73ebe91
evidence:
  - kind: blog
    url: https://yzhums.com/67343/
    title: "Business Central 2025 wave 2 (BC27): Truncating table data with new AL method (procedure Truncate)"
    date: "2025-09-04"
    commit: null
    t: null
    quote: null
  - kind: blog
    url: https://yzhums.com/67343/
    title: "Business Central 2025 wave 2 (BC27): Truncating table data with new AL method (procedure Truncate)"
    date: "2025-09-04"
    commit: null
    t: null
    quote: The new Rec.Truncate method in AL provides a powerful and efficient way to delete large volumes of data from a table.
  - kind: blog
    url: https://yzhums.com/67343/
    title: "Business Central 2025 wave 2 (BC27): Truncating table data with new AL method (procedure Truncate)"
    date: "2025-09-04"
    commit: null
    t: null
    quote: Truncate with a filter should only be used when the majority of the table is being deleted, as otherwise DeleteAll will be more efficient.
  - kind: blog
    url: https://yzhums.com/67343/
    title: "Business Central 2025 wave 2 (BC27): Truncating table data with new AL method (procedure Truncate)"
    date: "2025-09-04"
    commit: null
    t: null
    quote: Truncate allows for less concurrency than DeleteAll, as the entire table will be locked until the transaction is committed.
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
post_id: "67343"
source_id: yzhums-com
source_name: Dynamics 365 Lab - Yun Zhu
url: https://yzhums.com/67343/
published_at: "2025-09-04T06:12:41.000Z"
author: Yun Zhu
full_text: false
words: 560
quotes:
  - text: The new Rec.Truncate method in AL provides a powerful and efficient way to delete large volumes of data from a table.
    why_it_matters: Establishes the core value proposition of the feature for bulk data cleanup operations
  - text: Truncate with a filter should only be used when the majority of the table is being deleted, as otherwise DeleteAll will be more efficient.
    why_it_matters: Critical guidance for developers on when to apply this method to avoid performance degradation with filters
  - text: Truncate allows for less concurrency than DeleteAll, as the entire table will be locked until the transaction is committed.
    why_it_matters: Important trade-off consideration showing the performance benefit comes at the cost of table-level locking
code_objects_mentioned: []
systems:
  - development
  - platform
versions_mentioned:
  - BC27
  - 2025 Wave 2
cautions:
  - kind: gotcha
    quote: Truncate allows for less concurrency than DeleteAll, as the entire table will be locked until the transaction is committed.
    objects: []
    events: []
    versions:
      - BC27
  - kind: gotcha
    quote: Truncate with a filter should only be used when the majority of the table is being deleted, as otherwise DeleteAll will be more efficient.
    objects: []
    events: []
    versions:
      - BC27
  - kind: warning
    quote: Truncate is not supported when the OnBeforeDelete and/or OnAfterDelete event is subscribed.
    objects: []
    events:
      - OnBeforeDelete
      - OnAfterDelete
    versions:
      - BC27
  - kind: warning
    quote: Truncate is not supported when the field has Media and/or MediaSet fields.
    objects: []
    events: []
    versions:
      - BC27
preview:
  embeddable: true
  frame_url: null
  image: https://yzhums.com/wp-content/uploads/2025/09/Snipaste_2025-09-04_11-25-05.png
  image_alt: null
  image_w: null
  image_h: null
  site_name: Dynamics 365 Lab
  favicon: https://yzhums.com/wp-content/uploads/2020/08/cropped-logo-3-32x32.png
  probed_at: "2026-10-26T06:15:46.696Z"
---

# Business Central 2025 wave 2 (BC27): Truncating table data with new AL method (procedure Truncate)

[Read the post](https://yzhums.com/67343/) · Dynamics 365 Lab - Yun Zhu (Yun Zhu, MVP) · 2025-09-04 · 560 words · tier community · reviewed (checked by Opus)

> Business Central 2025 Wave 2 introduces the new Rec.Truncate AL method for efficiently deleting large volumes of table data in a single operation. This method improves performance over row-by-row DeleteAll operations by locking the table during the transaction, with configurable AutoIncrement behavior and delete permission checks, though it has several limitations including incompatibility with temporary tables, try functions, security filters, and tables with media fields.

## Key points

- Rec.Truncate (BC27) deletes all records in the current filter range far faster than row-by-row deletion, but locks the whole table until commit, so concurrency is lower than with DeleteAll.
- Optional parameters let you check whether truncation is unsupported for the table and choose whether AutoIncrement fields reset to 0 or keep their prior value; delete permissions are enforced.
- Not supported for temporary, system or non-Normal tables, inside try functions, with security filters, with filters on flow fields or many marked records, when OnBeforeDelete/OnAfterDelete are subscribed, or with Media/MediaSet fields; use DeleteAll there.
- With filters the platform copies data to a temporary table and back, so filtering only pays off when most rows are deleted; the author saw runtime errors when filtering or using FindSet on large deletions.

## Quotes

- "The new Rec.Truncate method in AL provides a powerful and efficient way to delete large volumes of data from a table." (Establishes the core value proposition of the feature for bulk data cleanup operations)
- "Truncate with a filter should only be used when the majority of the table is being deleted, as otherwise DeleteAll will be more efficient." (Critical guidance for developers on when to apply this method to avoid performance degradation with filters)
- "Truncate allows for less concurrency than DeleteAll, as the entire table will be locked until the transaction is committed." (Important trade-off consideration showing the performance benefit comes at the cost of table-level locking)

## Heads up

- gotcha: "Truncate allows for less concurrency than DeleteAll, as the entire table will be locked until the transaction is committed." (about version BC27)
- gotcha: "Truncate with a filter should only be used when the majority of the table is being deleted, as otherwise DeleteAll will be more efficient." (about version BC27)
- warning: "Truncate is not supported when the OnBeforeDelete and/or OnAfterDelete event is subscribed." (about OnBeforeDelete, OnAfterDelete, version BC27)
- warning: "Truncate is not supported when the field has Media and/or MediaSet fields." (about version BC27)

## Context

- Features: Truncate method, bulk data deletion, AutoIncrement control, delete permissions, table locking, filter support
- Versions: BC27, 2025 Wave 2

Source: Dynamics 365 Lab - Yun Zhu, community blog. Summary, key points and quotes are derived (CONTENT-NOTICE.md); read the original for the full text.
