---
title: "Codeunit 3902 Retention Policy Setup, extension points 29"
author: "JOP-AL"
url: https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/points/
object: https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/
app: "System Application"
major: 29
source: https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/
checked: 2026-11-20
changed: 2026-10-05
subject: "Microsoft Dynamics 365 Business Central"
license: "Metadata from Microsoft's symbol packages. AL source MIT, Copyright (c) Microsoft Corporation. Selection and wording © 2026 JOP-AL. https://jonas-paprotka.de/licenses/"
---

# Codeunit 3902 Retention Policy Setup, extension points 29

JOP-AL, https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/points/

18 procedures and triggers with a step in src/System Application/App/Retention Policy/src/Retention Policy Setup/RetentionPolicySetup.Codeunit.al, in source order, read from the text, not from a run.

## SetTableFilterView

[Line 25](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L25).

- [29](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L29) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `SetTableFilterView`

## GetTableFilterView

[Line 37](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L37).

- [41](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L41) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `GetTableFilterView`

## GetTableFilterText

[Line 49](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L49).

- [53](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L53) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `GetTableFilterText`

## TableIdLookup

[Line 61](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L61).

- [65](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L65) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `TableIdLookup`

## DateFieldNoLookup

[Line 74](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L74).

- [78](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L78) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `DateFieldNoLookup`

## IsRetentionPolicyEnabled

[Line 85](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L85).

- [89](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L89) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `IsRetentionPolicyEnabled`

## IsRetentionPolicyEnabled

[Line 97](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L97).

- [101](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L101) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `IsRetentionPolicyEnabled`

## FindOrCreateRetentionPeriod

[Line 109](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L109).

- [113](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L113) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `FindOrCreateRetentionPeriod`

## FindOrCreateRetentionPeriod

[Line 122](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L122).

- [126](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L126) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `FindOrCreateRetentionPeriod`

## FindOrCreateRetentionPeriod

[Line 135](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L135).

- [139](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L139) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `FindOrCreateRetentionPeriod`

## VerifyRetentionPolicySetupOnbeforeDeleteRetentionPeriod

[Line 144](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L144), local.

- [148](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L148) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `VerifyRetentionPolicySetupOnbeforeDeleteRetentionPeriod`

## VerifyRetentionPolicySetupOnbeforeModifyRetentionPeriod

[Line 152](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L152), local.

- [156](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L156) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `VerifyRetentionPolicySetupOnBeforeModifyRetentionPeriod`

## VerifyRetentionPolicyAllowedTablesOnBeforeInsertRetenPolSetup

[Line 160](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L160), local.

- [164](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L164) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `VerifyRetentionPolicyAllowedTablesOnBeforeInsertRetenPolSetup`

## InsertDefaultTableFiltersOnAfterInsertRetenPolSetup

[Line 168](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L168), local.

- [172](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L172) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `InsertDefaultTableFiltersOnAfterInsertRetenPolSetup`

## ErrorOnBeforeRenameRetentionPolicySetup

[Line 176](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L176), local.

- [184](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L184) calls [Codeunit 3908 Retention Policy Log](https://jonas-paprotka.de/ref/codeunit/3908-retention-policy-log/) `LogError`
- [184](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L184) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `LogCategory`

## ErrorOnBeforeRenameRetentionPolicySetupLine

[Line 188](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L188), local.

- [196](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L196) calls [Codeunit 3908 Retention Policy Log](https://jonas-paprotka.de/ref/codeunit/3908-retention-policy-log/) `LogError`
- [196](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L196) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `LogCategory`

## CheckRecordLockedOnRetentionPolicySetupLineOnAfterModify

[Line 200](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L200), local.

- [207](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L207) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `CheckRecordLockedOnRetentionPolicySetupLine`

## CheckRecordLockedOnRetentionPolicySetupLineOnAfterDelete

[Line 211](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L211), local.

- [215](https://jonas-paprotka.de/ref/codeunit/3902-retention-policy-setup/source/#L215) calls [Codeunit 3903 Retention Policy Setup Impl.](https://jonas-paprotka.de/ref/codeunit/3903-retention-policy-setup-impl/) `CheckRecordLockedOnRetentionPolicySetupLine`

## Source

AL source 29: https://github.com/microsoft/BCApps, MIT, releases/29.x at 4303e5e584d3aa5d9e98cbc615525a5396ad6ed7.

JOP-AL, 2026-11-20.
