---
title: "Table 21 Cust. Ledger Entry"
author: "Jonas Paprotka"
url: https://jonas-paprotka.de/ref/table/21-cust-ledger-entry/
type: table
id: 21
name: "Cust. Ledger Entry"
app: "Base Application"
namespace: Microsoft.Sales.Receivables
versions: "17-28"
build: 28.5.54151.54365
source: "https://jonas-paprotka.de/ref/table/21-cust-ledger-entry/source/29/"
checked: 2026-09-20
subject: "Microsoft Dynamics 365 Business Central"
license: "Content © 2026 Jonas Paprotka. Quote freely with attribution and a link."
---

# Table 21 Cust. Ledger Entry

Jonas Paprotka, https://jonas-paprotka.de/ref/table/21-cust-ledger-entry/

| | |
| --- | --- |
| App | Base Application |
| Namespace | Microsoft.Sales.Receivables |
| Versions | 17-28 |
| Source file | Sales/Receivables/CustLedgerEntry.Table.al |

## Fields

| Id | Name | Type | Versions | Obsolete | Reason |
| --- | --- | --- | --- | --- | --- |
| 1 | Entry No. | Integer | 17-28 | - | - |
| 3 | Customer No. | Code[20] | 17-28 | - | - |
| 4 | Posting Date | Date | 17-28 | - | - |
| 5 | Document Type | Enum Gen. Journal Document Type | 17-28 | - | - |
| 6 | Document No. | Code[20] | 17-28 | - | - |
| 7 | Description | Text[100] | 17-28 | - | - |
| 8 | Customer Name | Text[100] | 17-28 | - | - |
| 10 | Your Reference | Text[35] | 22-28 | - | - |
| 11 | Currency Code | Code[10] | 17-28 | - | - |
| 13 | Amount | Decimal | 17-28 | - | - |
| 14 | Remaining Amount | Decimal | 17-28 | - | - |
| 15 | Original Amt. (LCY) | Decimal | 17-28 | - | - |
| 16 | Remaining Amt. (LCY) | Decimal | 17-28 | - | - |
| 17 | Amount (LCY) | Decimal | 17-28 | - | - |
| 18 | Sales (LCY) | Decimal | 17-28 | - | - |
| 19 | Profit (LCY) | Decimal | 17-28 | - | - |
| 20 | Inv. Discount (LCY) | Decimal | 17-28 | - | - |
| 21 | Sell-to Customer No. | Code[20] | 17-28 | - | - |
| 22 | Customer Posting Group | Code[20] | 17-28 | - | - |
| 23 | Global Dimension 1 Code | Code[20] | 17-28 | - | - |
| 24 | Global Dimension 2 Code | Code[20] | 17-28 | - | - |
| 25 | Salesperson Code | Code[20] | 17-28 | - | - |
| 27 | User ID | Code[50] | 17-28 | - | - |
| 28 | Source Code | Code[10] | 17-28 | - | - |
| 33 | On Hold | Code[3] | 17-28 | - | - |
| 34 | Applies-to Doc. Type | Enum Gen. Journal Document Type | 17-28 | - | - |
| 35 | Applies-to Doc. No. | Code[20] | 17-28 | - | - |
| 36 | Open | Boolean | 17-28 | - | - |
| 37 | Due Date | Date | 17-28 | - | - |
| 38 | Pmt. Discount Date | Date | 17-28 | - | - |
| 39 | Original Pmt. Disc. Possible | Decimal | 17-28 | - | - |
| 40 | Pmt. Disc. Given (LCY) | Decimal | 17-28 | - | - |
| 42 | Orig. Pmt. Disc. Possible(LCY) | Decimal | 20-28 | - | - |
| 43 | Positive | Boolean | 17-28 | - | - |
| 44 | Closed by Entry No. | Integer | 17-28 | - | - |
| 45 | Closed at Date | Date | 17-28 | - | - |
| 46 | Closed by Amount | Decimal | 17-28 | - | - |
| 47 | Applies-to ID | Code[50] | 17-28 | - | - |
| 48 | Journal Templ. Name | Code[10] | 20-28 | - | - |
| 49 | Journal Batch Name | Code[10] | 17-28 | - | - |
| 50 | Reason Code | Code[10] | 17-28 | - | - |
| 51 | Bal. Account Type | Enum Gen. Journal Account Type | 17-28 | - | - |
| 52 | Bal. Account No. | Code[20] | 17-28 | - | - |
| 53 | Transaction No. | Integer | 17-28 | - | - |
| 54 | Closed by Amount (LCY) | Decimal | 17-28 | - | - |
| 58 | Debit Amount | Decimal | 17-28 | - | - |
| 59 | Credit Amount | Decimal | 17-28 | - | - |
| 60 | Debit Amount (LCY) | Decimal | 17-28 | - | - |
| 61 | Credit Amount (LCY) | Decimal | 17-28 | - | - |
| 62 | Document Date | Date | 17-28 | - | - |
| 63 | External Document No. | Code[35] | 17-28 | - | - |
| 64 | Calculate Interest | Boolean | 17-28 | - | - |
| 65 | Closing Interest Calculated | Boolean | 17-28 | - | - |
| 66 | No. Series | Code[20] | 17-28 | - | - |
| 67 | Closed by Currency Code | Code[10] | 17-28 | - | - |
| 68 | Closed by Currency Amount | Decimal | 17-28 | - | - |
| 73 | Adjusted Currency Factor | Decimal | 17-28 | - | - |
| 74 | Original Currency Factor | Decimal | 17-28 | - | - |
| 75 | Original Amount | Decimal | 17-28 | - | - |
| 76 | Date Filter | Date | 17-28 | - | - |
| 77 | Remaining Pmt. Disc. Possible | Decimal | 17-28 | - | - |
| 78 | Pmt. Disc. Tolerance Date | Date | 17-28 | - | - |
| 79 | Max. Payment Tolerance | Decimal | 17-28 | - | - |
| 80 | Last Issued Reminder Level | Integer | 17-28 | - | - |
| 81 | Accepted Payment Tolerance | Decimal | 17-28 | - | - |
| 82 | Accepted Pmt. Disc. Tolerance | Boolean | 17-28 | - | - |
| 83 | Pmt. Tolerance (LCY) | Decimal | 17-28 | - | - |
| 84 | Amount to Apply | Decimal | 17-28 | - | - |
| 85 | IC Partner Code | Code[20] | 17-28 | - | - |
| 86 | Applying Entry | Boolean | 17-28 | - | - |
| 87 | Reversed | Boolean | 17-28 | - | - |
| 88 | Reversed by Entry No. | Integer | 17-28 | - | - |
| 89 | Reversed Entry No. | Integer | 17-28 | - | - |
| 90 | Prepayment | Boolean | 17-28 | - | - |
| 171 | Payment Reference | Code[50] | 17-28 | - | - |
| 172 | Payment Method Code | Code[10] | 17-28 | - | - |
| 173 | Applies-to Ext. Doc. No. | Code[35] | 17-28 | - | - |
| 288 | Recipient Bank Account | Code[20] | 17-28 | - | - |
| 289 | Message to Recipient | Text[140] | 17-28 | - | - |
| 290 | Exported to Payment File | Boolean | 17-28 | - | - |
| 480 | Dimension Set ID | Integer | 17-28 | - | - |
| 481 | Shortcut Dimension 3 Code | Code[20] | 17-28 | - | - |
| 482 | Shortcut Dimension 4 Code | Code[20] | 17-28 | - | - |
| 483 | Shortcut Dimension 5 Code | Code[20] | 17-28 | - | - |
| 484 | Shortcut Dimension 6 Code | Code[20] | 17-28 | - | - |
| 485 | Shortcut Dimension 7 Code | Code[20] | 17-28 | - | - |
| 486 | Shortcut Dimension 8 Code | Code[20] | 17-28 | - | - |
| 1200 | Direct Debit Mandate ID | Code[35] | 17-28 | - | - |
| 1340 | Dispute Status | Code[10] | 24-28 | - | - |
| 1341 | Promised Pay Date | Date | 24-28 | - | - |

## Keys

| Name | Fields | Versions |
| --- | --- | --- |
| Key1, clustered | Entry No. | 17-28 |
| Key2 | Customer No., Currency Code | 17-28 |
| Key3 | Customer No., Currency Code, Posting Date | 17-21 |
| Key4 | Document No. | 17-28 |
| Key5 | External Document No. | 17-28 |
| Key6 | Customer No., Open, Positive, Due Date, Currency Code | 17-28 |
| Key7 | Open, Due Date | 17-28 |
| Key8 | Customer No., Document Type, Posting Date, Currency Code | 17-28 |
| Key9 | Salesperson Code, Posting Date | 17-28 |
| Key10 | Closed by Entry No. | 17-28 |
| Key11 | Transaction No. | 17-28 |
| Key12 | Customer No., Open, Positive, Calculate Interest, Due Date | 17-21 |
| Key13 | Customer No., Global Dimension 1 Code, Global Dimension 2 Code, Posting Date, Currency Code | 17-21 |
| Key14 | Customer No., Open, Global Dimension 1 Code, Global Dimension 2 Code, Positive, Due Date, Currency Code | 17-21 |
| Key15 | Open, Global Dimension 1 Code, Global Dimension 2 Code, Due Date | 17-21 |
| Key16 | Document Type, Customer No., Global Dimension 1 Code, Global Dimension 2 Code, Posting Date, Currency Code | 17-21 |
| Key17 | Customer No., Applies-to ID, Open, Positive, Due Date | 17-28 |
| Key18 | Document Type, Posting Date | 17-28 |
| Key19 | Document Type, Customer No., Open, Due Date | 17-28 |
| Key20 | Customer Posting Group | 17-28 |
| Key21 | Document Type, Open, Posting Date, Closed at Date | 17-28 |
| Key22 | Salesperson Code | 17-28 |
| Key23 | SystemModifiedAt | 17-28 |
| Key35 | Customer No., Posting Date, Applies-to ID | 19-28 |
| Key36 | Document Type, Reversed, Posting Date | 22-28 |
| Key37 | Applies-to ID | 25-28 |

## Procedures

| Name | Parameters | Returns | Access | Versions | Obsolete | Reason |
| --- | --- | --- | --- | --- | --- | --- |
| GetLastEntryNo | () | Integer | public | 17-28 | - | - |
| ShowDoc | () | Boolean | public | 17-28 | - | - |
| ShowPostedDocAttachment | () | - | public | 17-28 | - | - |
| HasPostedDocAttachment | () | Boolean | public | 17-28 | - | - |
| DrillDownOnEntries | (var Record Detailed Cust. Ledg. Entry) | - | public | 17-28 | - | - |
| DrillDownOnOverdueEntries | (var Record Detailed Cust. Ledg. Entry) | - | public | 17-28 | - | - |
| GetOriginalCurrencyFactor | () | Decimal | public | 17-28 | - | - |
| GetAdjustedCurrencyFactor | () | Decimal | public | 17-28 | - | - |
| ShowDimensions | () | - | public | 17-28 | - | - |
| SetStyle | () | Text | public | 17-28 | - | - |
| SetApplyToFilters | (Code[20], Option, Code[20], Decimal) | - | public | 17-28 | - | - |
| SetAmountToApply | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| CopyFromGenJnlLine | (Record Gen. Journal Line) | - | public | 17-28 | - | - |
| CopyFromCVLedgEntryBuffer | (var Record CV Ledger Entry Buffer) | - | public | 17-28 | - | - |
| RecalculateAmounts | (Code[10], Code[10], Date) | - | public | 17-28 | - | - |
| UpdateAmountsForApplication | (Date, Code[10], Boolean, Boolean) | - | public | 23-28 | - | - |
| GetRemainingPmtDiscPossible | (Date) | Decimal | public | 23-28 | - | - |

## Events

| Kind | Name | Parameters | Versions | Obsolete | Reason |
| --- | --- | --- | --- | --- | --- |
| Integration event | OnAfterCopyCustLedgerEntryFromGenJnlLine | (var Record Cust. Ledger Entry, Record Gen. Journal Line) | 17-28 | - | - |
| Integration event | OnAfterCopyCustLedgerEntryFromCVLedgEntryBuffer | (var Record Cust. Ledger Entry, Record CV Ledger Entry Buffer) | 17-28 | - | - |
| Integration event | OnAfterRecalculateAmounts | (var Record Cust. Ledger Entry, Code[10], Code[10], Date) | 17-28 | - | - |
| Integration event | OnAfterShowDoc | (Record Cust. Ledger Entry) | 17 | - | - |
| Integration event | OnBeforeDrillDownEntries | (var Record Cust. Ledger Entry, var Record Detailed Cust. Ledg. Entry, var Integer) | 17-28 | - | - |
| Integration event | OnBeforeDrillDownOnOverdueEntries | (var Record Cust. Ledger Entry, var Record Detailed Cust. Ledg. Entry, var Integer) | 17-28 | - | - |
| Integration event | OnBeforeSetAmountToApply | (var Record Cust. Ledger Entry) | 17 | - | - |
| Integration event | OnBeforeSetStyle | (var Text, var Boolean) | 17-28 | - | - |
| Integration event | OnBeforeShowDoc | (Record Cust. Ledger Entry, var Boolean, var Boolean) | 17-28 | - | - |
| Integration event | OnAfterShowDoc | (var Record Cust. Ledger Entry) | 18-28 | - | - |
| Integration event | OnAfterShowPostedDocAttachment | (var Record Cust. Ledger Entry) | 18-24 | - | - |
| Integration event | OnAfterHasPostedDocAttachment | (var Record Cust. Ledger Entry, var Boolean) | 18-28 | - | - |
| Integration event | OnBeforeSetAmountToApply | (var Record Cust. Ledger Entry, Code[20], Code[20]) | 18-28 | - | - |
| Integration event | OnBeforeValidateMessagetoRecipient | (var Record Cust. Ledger Entry, var Boolean) | 20-28 | - | - |
| Integration event | OnAfterUpdateAmountsForApplication | (var Record Cust. Ledger Entry, Date, Code[10], Boolean, Boolean) | 23-28 | - | - |
| Integration event | OnAfterGetRemainingPmtDiscPossible | (Record Cust. Ledger Entry, Date, var Decimal) | 23-28 | - | - |
| Integration event | OnBeforeDrillDownOnOverdueEntriesBeforeCode | (var Record Detailed Cust. Ledg. Entry, var Boolean) | 23-28 | - | - |
| Integration event | OnBeforeRecalculateAmounts | (var Record Cust. Ledger Entry, Code[10], Code[10], Date, var Boolean) | 24-28 | - | - |
| Integration event | OnBeforeUpdateAmountsForApplication | (var Record Cust. Ledger Entry, Date, Code[10], Boolean, Boolean, var Boolean) | 24-28 | - | - |
| Integration event | OnValidateAmounttoApplyBeforeFieldError | (var Record Cust. Ledger Entry) | 25-28 | - | - |
| Integration event | OnAfterShowPostedDocAttachment | (var Record Cust. Ledger Entry, Boolean) | 25-28 | - | - |
| Integration event | OnSetAmountToApplyOnAfterCalcRemainingAmount | (var Record Cust. Ledger Entry) | 25-28 | - | - |
| Integration event | OnValidateMaxPaymentToleranceOnBeforeFieldError | (var Record Cust. Ledger Entry) | 25-28 | - | - |

## Source

Symbols: Microsoft.BaseApplication.symbols.437dbf0e-84ff-417a-965d-ed2bb9650972, https://dynamicssmb2.pkgs.visualstudio.com/DynamicsBCPublicFeeds/_packaging/MSSymbols/nuget/v3/index.json, highest build per major on 2026-09-20.
AL source 29: https://github.com/microsoft/BCApps, MIT, releases/29.x at a66254c3b8b5bb1cea290dc8f9d097aec4381153.

Jonas Paprotka, 2026-09-20.
