---
id: object/table/5107
type: object
title: Table 5107 "Sales Header Archive"
summary: Table 5107 "Sales Header Archive" in Base Application (Microsoft.Sales.Archive). 169 fields, 3 public procedures, 1 events. Present since at least BC23, still in BC30, changed in BC24-28.
tier: official
language: en
tags:
  - table
  - base application
versions:
  introduced: null
  last_changed: "28"
  deprecated: null
review:
  state: derived
  by: null
  at: null
  flags: []
generated:
  at: "2026-10-11T00:31:51.816Z"
  pipeline: 0.2.0
  prompts: {}
  input_hash: 5bf407470eef8136d39cc3c4c5383e83b1b18de2a51bf7d4064ee19121d51f3c
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/Sales/Archive/SalesHeaderArchive.Table.al
    title: src/Layers/W1/BaseApp/Sales/Archive/SalesHeaderArchive.Table.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn:
    - https://learn.microsoft.com/dynamics365/business-central/sales-how-process-sales-returns-cancellations
    - https://learn.microsoft.com/dynamics365/business-central/sales-how-process-sales-returns-orders
    - https://learn.microsoft.com/dynamics365/business-central/across-how-to-archive-documents
    - https://learn.microsoft.com/dynamics365/business-central/sales-how-to-create-blanket-sales-orders
  objects: []
  features: []
  topics:
    - topic/business-central/business-functionality/general-business-functionality
    - topic/business-central/business-functionality/purchasing
    - topic/business-central/business-functionality/sales
  localizations:
    - localization/au
    - localization/be
    - localization/ca
    - localization/ch
    - localization/it
    - localization/mx
    - localization/no
    - localization/nz
    - localization/ru
    - localization/us
  videos: []
  posts: []
  guidelines: []
object_type: table
object_id: 5107
name: Sales Header Archive
namespace: Microsoft.Sales.Archive
app: Base Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
source_major: "29"
obsolete: null
countries:
  - au
  - be
  - ca
  - ch
  - it
  - mx
  - "no"
  - nz
  - ru
  - us
ms_search_form_ids: []
counts:
  fields: 169
  procedures: 4
  events: 1
  subscribers: 0
relations:
  out: 75
  referenced_by: 7
  pages: 13
  extended_by: 1
  event_subscribers: 0
  calls: 4
  called_by: 0
  implements: 0
---

# Table 5107 "Sales Header Archive"

> Table 5107 "Sales Header Archive" in Base Application (Microsoft.Sales.Archive). 169 fields, 3 public procedures, 1 events. Present since at least BC23, still in BC30, changed in BC24-28.

Base Application · Microsoft.Sales.Archive · BC23-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/Sales/Archive/SalesHeaderArchive.Table.al) · facts from BC29

Learn documents this table through its pages: [Page 6629 "Sales Return List Archive"](../page/6629.md) (2 Learn pages), [Page 5159 "Sales Order Archive"](../page/5159.md) (1), [Page 5162 "Sales Quote Archive"](../page/5162.md) (1), [Page 6620 "Blanket Sales Order Archive"](../page/6620.md) (1), [Page 6622 "Blanket Sales Order Archives"](../page/6622.md) (1), [Page 6627 "Sales Return Order Archive"](../page/6627.md) (1), [Page 9348 "Sales Quote Archives"](../page/9348.md) (1), [Page 9349 "Sales Order Archives"](../page/9349.md) (1).

## Properties

| Property | Value |
|---|---|
| Caption | Sales Header Archive |
| DataClassification | CustomerContent |

## Fields

Explanation: the field's ToolTip in the code; without one, the ToolTip of a page control bound to the field (marked via the page); without that, its Caption (marked caption) when that differs from the name.

| No. | Name | Type | Explanation | Notes |
|---|---|---|---|---|
| 1 | Document Type | Enum "Sales Document Type" | — | enum [Enum 36 "Sales Document Type"](../enum/36.md) |
| 2 | Sell-to Customer No. | Code[20] | Specifies the number of the customer who will receive the products and be billed by default. | TableRelation [Table 18 "Customer"](../table/18.md) |
| 3 | No. | Code[20] | Specifies the number of the involved entry or record, according to the specified number series. |  |
| 4 | Bill-to Customer No. | Code[20] | Specifies the number of the customer that you send or sent the invoice or credit memo to. | TableRelation [Table 18 "Customer"](../table/18.md); NotBlank |
| 5 | Bill-to Name | Text[100] | Specifies the name of the customer that you send or sent the invoice or credit memo to. |  |
| 6 | Bill-to Name 2 | Text[50] | Specifies an additional part of the name of the customer that you send or sent the invoice or credit memo to. |  |
| 7 | Bill-to Address | Text[100] | Specifies the address of the customer to whom you sent the invoice. |  |
| 8 | Bill-to Address 2 | Text[50] | Specifies an additional line of the address. |  |
| 9 | Bill-to City | Text[30] | Specifies the city of the address. | TableRelation [Table 225 "Post Code"](../table/225.md) ("Post Code".City) |
| 10 | Bill-to Contact | Text[100] | Specifies the name of the contact person at the customer's billing address. |  |
| 11 | Your Reference | Text[35] | Specifies the customer's reference. The content will be printed on sales documents. |  |
| 12 | Ship-to Code | Code[10] | Specifies a code for an alternate shipment address if you want to ship to another address than the one that has been entered automatically. This field is also used in case of drop shipment. | TableRelation [Table 222 "Ship-to Address"](../table/222.md) ("Ship-to Address".Code where("Customer No." = field("Sell-to Customer No."))) |
| 13 | Ship-to Name | Text[100] | Specifies the name of the customer at the address that the items are shipped to. |  |
| 14 | Ship-to Name 2 | Text[50] | Specifies an additional part of the name of the customer at the address that the items are shipped to. |  |
| 15 | Ship-to Address | Text[100] | Specifies the address that the items are shipped to. |  |
| 16 | Ship-to Address 2 | Text[50] | Specifies an additional part of the ship-to address, in case it is a long address. |  |
| 17 | Ship-to City | Text[30] | Specifies the city of the address that the items are shipped to. | TableRelation [Table 225 "Post Code"](../table/225.md) ("Post Code".City) |
| 18 | Ship-to Contact | Text[100] | Specifies the name of the contact person at the address that the items are shipped to. |  |
| 19 | Order Date | Date | Specifies the date the order was created. The order date is also used to determine the prices and discounts on the document. |  |
| 20 | Posting Date | Date | Specifies the date when the document was posted. |  |
| 21 | Shipment Date | Date | Specifies when items on the document are shipped or were shipped. A shipment date is usually calculated from a requested delivery date plus lead time. |  |
| 22 | Posting Description | Text[100] | — |  |
| 23 | Payment Terms Code | Code[10] | Specifies a formula that calculates the payment due date, payment discount date, and payment discount amount on the sales document. | TableRelation [Table 3 "Payment Terms"](../table/3.md) (Payment Terms) |
| 24 | Due Date | Date | Specifies when the related sales invoice must be paid. |  |
| 25 | Payment Discount % | Decimal | Specifies the payment discount percentage that is granted if the customer pays on or before the date entered in the Pmt. Discount Date field. The discount percentage is specified in the Payment Terms Code field. |  |
| 26 | Pmt. Discount Date | Date | Specifies the date on which the amount in the entry must be paid for a payment discount to be granted. |  |
| 27 | Shipment Method Code | Code[10] | Specifies the delivery conditions of the related shipment, such as free on board (FOB). | TableRelation [Table 10 "Shipment Method"](../table/10.md) (Shipment Method) |
| 28 | Location Code | Code[10] | Specifies the location from where items are to be shipped. This field acts as the default location for new lines. Location code for individual lines can differ from it. | TableRelation [Table 14 "Location"](../table/14.md) (Location where("Use As In-Transit" = const(false))) |
| 29 | Shortcut Dimension 1 Code | Code[20] | Specifies the code for Shortcut Dimension 1, which is one of two global dimension codes that you set up in the General Ledger Setup window. | TableRelation [Table 349 "Dimension Value"](../table/349.md) ("Dimension Value".Code where("Global Dimension No." = const(1))) |
| 30 | Shortcut Dimension 2 Code | Code[20] | Specifies the code for Shortcut Dimension 2, which is one of two global dimension codes that you set up in the General Ledger Setup window. | TableRelation [Table 349 "Dimension Value"](../table/349.md) ("Dimension Value".Code where("Global Dimension No." = const(2))) |
| 31 | Customer Posting Group | Code[20] | — | TableRelation [Table 92 "Customer Posting Group"](../table/92.md) (Customer Posting Group) |
| 32 | Currency Code | Code[10] | Specifies the currency that is used on the entry. | TableRelation [Table 4 "Currency"](../table/4.md) |
| 33 | Currency Factor | Decimal | — |  |
| 34 | Price Group Code | Code[10] | — | TableRelation [Table 6 "Customer Price Group"](../table/6.md) (Customer Price Group) |
| 35 | Prices Including VAT | Boolean | Specifies if the Unit Price and Line Amount fields on document lines should be shown with or without VAT. |  |
| 37 | Invoice Disc. Code | Code[20] | — |  |
| 40 | Cust./Item Disc. Gr. | Code[20] | — | TableRelation [Table 340 "Customer Discount Group"](../table/340.md) (Customer Discount Group) |
| 41 | Language Code | Code[10] | — | TableRelation [Table 8 "Language"](../table/8.md) |
| 42 | Format Region | Text[80] | — | TableRelation "Language Selection"."Language Tag" |
| 43 | Salesperson Code | Code[20] | Specifies which salesperson is associated with the sales document. | TableRelation [Table 13 "Salesperson/Purchaser"](../table/13.md) (Salesperson/Purchaser) |
| 45 | Order Class | Code[10] | — |  |
| 46 | Comment | Boolean | — | FlowField: exist("Sales Comment Line Archive" where("Document Type" = field("Document Type"), "No." = field("No."), "Document Line No." = const(0), "Doc. No. Occurrence" = field("Doc. No. Occurrence"), "Version No." = field("Version No."))); not editable |
| 47 | No. Printed | Integer | — |  |
| 51 | On Hold | Code[3] | — |  |
| 52 | Applies-to Doc. Type | Enum "Gen. Journal Document Type" | Specifies the type of the posted document that this document or journal line will be applied to when you post, for example to register payment. | enum [Enum 6 "Gen. Journal Document Type"](../enum/6.md) |
| 53 | Applies-to Doc. No. | Code[20] | Specifies the number of the posted document that this document or journal line will be applied to when you post, for example to register payment. |  |
| 55 | Bal. Account No. | Code[20] | — | TableRelation [Table 15 "G/L Account"](../table/15.md), [Table 270 "Bank Account"](../table/270.md) (if ("Bal. Account Type" = const("G/L Account")) "G/L Account" else if ("Bal. Account Type" = const("Bank Account")) "Bank Account") |
| 57 | Ship | Boolean | — |  |
| 58 | Invoice | Boolean | — |  |
| 60 | Amount | Decimal | — | FlowField: sum("Sales Line Archive".Amount where("Document Type" = field("Document Type"), "Document No." = field("No."), "Doc. No. Occurrence" = field("Doc. No. Occurrence"), "Version No." = field("Version No."))); not editable |
| 61 | Amount Including VAT | Decimal | — | FlowField: sum("Sales Line Archive"."Amount Including VAT" where("Document Type" = field("Document Type"), "Document No." = field("No."), "Doc. No. Occurrence" = field("Doc. No. Occurrence"), "Version No." = field("Version No."))); not editable |
| 62 | Shipping No. | Code[20] | — |  |
| 63 | Posting No. | Code[20] | — |  |
| 64 | Last Shipping No. | Code[20] | — | TableRelation [Table 110 "Sales Shipment Header"](../table/110.md) (Sales Shipment Header) |
| 65 | Last Posting No. | Code[20] | — | TableRelation [Table 112 "Sales Invoice Header"](../table/112.md) (Sales Invoice Header) |
| 66 | Prepayment No. | Code[20] | — |  |
| 67 | Last Prepayment No. | Code[20] | — | TableRelation [Table 112 "Sales Invoice Header"](../table/112.md) (Sales Invoice Header) |
| 68 | Prepmt. Cr. Memo No. | Code[20] | — |  |
| 69 | Last Prepmt. Cr. Memo No. | Code[20] | — | TableRelation [Table 112 "Sales Invoice Header"](../table/112.md) (Sales Invoice Header) |
| 70 | VAT Registration No. | Text[20] | — |  |
| 71 | Combine Shipments | Boolean | — |  |
| 73 | Reason Code | Code[10] | — | TableRelation [Table 231 "Reason Code"](../table/231.md) (Reason Code) |
| 74 | Gen. Bus. Posting Group | Code[20] | — | TableRelation [Table 250 "Gen. Business Posting Group"](../table/250.md) (Gen. Business Posting Group) |
| 75 | EU 3-Party Trade | Boolean | Specifies if the transaction is related to trade with a third party within the EU. |  |
| 76 | Transaction Type | Code[10] | Specifies the type of transaction that the document represents, for the purpose of reporting to INTRASTAT. | TableRelation [Table 258 "Transaction Type"](../table/258.md) (Transaction Type) |
| 77 | Transport Method | Code[10] | Specifies the transport method, for the purpose of reporting to INTRASTAT. | TableRelation [Table 259 "Transport Method"](../table/259.md) (Transport Method) |
| 78 | VAT Country/Region Code | Code[10] | — | TableRelation [Table 9 "Country/Region"](../table/9.md) (Country/Region) |
| 79 | Sell-to Customer Name | Text[100] | Specifies the name of the customer who will receive the products and be billed by default. |  |
| 80 | Sell-to Customer Name 2 | Text[50] | Specifies an additional part of the name of the customer who will receive the products and be billed by default. |  |
| 81 | Sell-to Address | Text[100] | Specifies the main address of the customer. |  |
| 82 | Sell-to Address 2 | Text[50] | Specifies an additional part of the address. |  |
| 83 | Sell-to City | Text[30] | Specifies the city of the customer's main address. | TableRelation [Table 225 "Post Code"](../table/225.md) ("Post Code".City) |
| 84 | Sell-to Contact | Text[100] | Specifies the name of the contact person at the customer's main address. |  |
| 85 | Bill-to Post Code | Code[20] | Specifies the postal code of the customer's billing address. | TableRelation [Table 225 "Post Code"](../table/225.md) (Post Code) |
| 86 | Bill-to County | Text[30] | Specifies the county of the customer on the sales document. |  |
| 87 | Bill-to Country/Region Code | Code[10] | Specifies the country or region of the customer on the sales document. | TableRelation [Table 9 "Country/Region"](../table/9.md) (Country/Region) |
| 88 | Sell-to Post Code | Code[20] | Specifies the postal code of the customer's main address. | TableRelation [Table 225 "Post Code"](../table/225.md) (Post Code) |
| 89 | Sell-to County | Text[30] | Specifies the county of your customer. |  |
| 90 | Sell-to Country/Region Code | Code[10] | Specifies the country or region of your customer. | TableRelation [Table 9 "Country/Region"](../table/9.md) (Country/Region) |
| 91 | Ship-to Post Code | Code[20] | Specifies the postal code of the address that the items are shipped to. | TableRelation [Table 225 "Post Code"](../table/225.md) (Post Code) |
| 92 | Ship-to County | Text[30] | Specifies the county of the ship-to address. |  |
| 93 | Ship-to Country/Region Code | Code[10] | Specifies the country/region code of the address that the items are shipped to. | TableRelation [Table 9 "Country/Region"](../table/9.md) (Country/Region) |
| 94 | Bal. Account Type | enum "Payment Balance Account Type" | — | enum [Enum 96 "Payment Balance Account Type"](../enum/96.md) |
| 97 | Exit Point | Code[10] | Specifies the point of exit through which you ship the items out of your country/region, for reporting to Intrastat. | TableRelation [Table 282 "Entry/Exit Point"](../table/282.md) (Entry/Exit Point) |
| 98 | Correction | Boolean | — |  |
| 99 | Document Date | Date | Specifies the date the document was created. |  |
| 100 | External Document No. | Code[35] | Specifies a document number that refers to the customer's or vendor's numbering system. |  |
| 101 | Area | Code[10] | Specifies the country or region of origin for the purpose of Intrastat reporting. | TableRelation [Table 284 "Area"](../table/284.md) |
| 102 | Transaction Specification | Code[10] | Specifies a specification of the document's transaction, for the purpose of reporting to INTRASTAT. | TableRelation [Table 285 "Transaction Specification"](../table/285.md) (Transaction Specification) |
| 104 | Payment Method Code | Code[10] | Specifies how the customer must pay for products on the sales document. | TableRelation [Table 289 "Payment Method"](../table/289.md) (Payment Method) |
| 105 | Shipping Agent Code | Code[10] | Specifies the code for the shipping agent who is transporting the items. | TableRelation [Table 291 "Shipping Agent"](../table/291.md) (Shipping Agent) |
| 106 | Package Tracking No. | Text[50] | Specifies the shipping agent's package number. |  |
| 107 | No. Series | Code[20] | — | TableRelation [Table 308 "No. Series"](../table/308.md) (No. Series) |
| 108 | Posting No. Series | Code[20] | — | TableRelation [Table 308 "No. Series"](../table/308.md) (No. Series) |
| 109 | Shipping No. Series | Code[20] | — | TableRelation [Table 308 "No. Series"](../table/308.md) (No. Series) |
| 114 | Tax Area Code | Code[20] | Specifies the tax area that is used to calculate and post sales tax. | TableRelation [Table 318 "Tax Area"](../table/318.md) (Tax Area) |
| 115 | Tax Liable | Boolean | Specifies if the customer or vendor is liable for sales tax. |  |
| 116 | VAT Bus. Posting Group | Code[20] | Specifies the VAT specification of the involved customer or vendor to link transactions made for this record with the appropriate general ledger account according to the VAT posting setup. | TableRelation [Table 323 "VAT Business Posting Group"](../table/323.md) (VAT Business Posting Group) |
| 117 | Reserve | Enum "Reserve Method" | — | enum [Enum 100 "Reserve Method"](../enum/100.md) |
| 118 | Applies-to ID | Code[50] | Specifies the ID of entries that will be applied to when you choose the Apply Entries action. |  |
| 119 | VAT Base Discount % | Decimal | — |  |
| 120 | Status | Enum "Sales Document Status" | Specifies whether the document is open, waiting to be approved, has been invoiced for prepayment, or has been released to the next stage of processing. | enum [Enum 3612 "Sales Document Status"](../enum/3612.md) |
| 121 | Invoice Discount Calculation | Option | — | OptionCaption: None,%,Amount |
| 122 | Invoice Discount Value | Decimal | — |  |
| 123 | Send IC Document | Boolean | — |  |
| 124 | IC Status | Enum "Sales Document IC Status" | — | enum [Enum 124 "Sales Document IC Status"](../enum/124.md) |
| 125 | Sell-to IC Partner Code | Code[20] | — | TableRelation [Table 413 "IC Partner"](../table/413.md) (IC Partner); not editable |
| 126 | Bill-to IC Partner Code | Code[20] | — | TableRelation [Table 413 "IC Partner"](../table/413.md) (IC Partner); not editable |
| 127 | IC Reference Document No. | Code[20] | — | not editable |
| 129 | IC Direction | Enum "IC Direction Type" | — | enum [Enum 129 "IC Direction Type"](../enum/129.md) |
| 130 | Prepayment % | Decimal | — |  |
| 131 | Prepayment No. Series | Code[20] | — | TableRelation [Table 308 "No. Series"](../table/308.md) (No. Series) |
| 132 | Compress Prepayment | Boolean | — |  |
| 133 | Prepayment Due Date | Date | — |  |
| 134 | Prepmt. Cr. Memo No. Series | Code[20] | — | TableRelation [Table 308 "No. Series"](../table/308.md) (No. Series) |
| 135 | Prepmt. Posting Description | Text[100] | — |  |
| 138 | Prepmt. Pmt. Discount Date | Date | — |  |
| 139 | Prepmt. Payment Terms Code | Code[10] | — | TableRelation [Table 3 "Payment Terms"](../table/3.md) (Payment Terms) |
| 140 | Prepmt. Payment Discount % | Decimal | — |  |
| 145 | No. of Archived Versions | Integer | — | FlowField: max("Sales Header Archive"."Version No." where("Document Type" = field("Document Type"), "No." = field("No."), "Doc. No. Occurrence" = field("Doc. No. Occurrence"))); not editable |
| 151 | Sales Quote No. | Code[20] | — | TableRelation [Table 36 "Sales Header"](../table/36.md) ("Sales Header"."No." where("Document Type" = const(Quote), "No." = field("Sales Quote No."))); not editable |
| 152 | Quote Valid Until Date | Date | Specifies how long the quote is valid. |  |
| 153 | Quote Sent to Customer | DateTime | — |  |
| 154 | Quote Accepted | Boolean | — |  |
| 155 | Quote Accepted Date | Date | — | not editable |
| 163 | Company Bank Account Code | Code[20] | — | TableRelation [Table 270 "Bank Account"](../table/270.md) ("Bank Account" where("Currency Code" = field("Currency Code"))) |
| 165 | Incoming Document Entry No. | Integer | — | TableRelation [Table 130 "Incoming Document"](../table/130.md) (Incoming Document) |
| 171 | Sell-to Phone No. | Text[30] | — |  |
| 172 | Sell-to E-Mail | Text[80] | — |  |
| 179 | VAT Reporting Date | Date | Specifies the entry's VAT date. |  |
| 181 | Rcvd.-from Count./Region Code | Code[10] | Received-from Country/Region Code <small>caption</small> | TableRelation [Table 9 "Country/Region"](../table/9.md) (Country/Region) |
| 200 | Work Description | BLOB | — |  |
| 210 | Ship-to Phone No. | Text[30] | Specifies the telephone number of the company's shipping address. |  |
| 480 | Dimension Set ID | Integer | — | TableRelation [Table 480 "Dimension Set Entry"](../table/480.md) (Dimension Set Entry); not editable |
| 3998 | Source Doc. Exists | Boolean | — | FlowField: exist("Sales Header" where("Document Type" = field("Document Type"), "No." = field("No."))); not editable |
| 3999 | Last Archived Date | DateTime | — | FlowField: max("Sales Header Archive".SystemCreatedAt where("Document Type" = field("Document Type"), "No." = field("No."), "Doc. No. Occurrence" = field("Doc. No. Occurrence"))); not editable |
| 5043 | Interaction Exist | Boolean | Specifies that the archived document is linked to an interaction log entry. |  |
| 5044 | Time Archived | Time | Specifies what time the document was archived. |  |
| 5045 | Date Archived | Date | Specifies the date when the document was archived. |  |
| 5046 | Archived By | Code[50] | Specifies the user ID of the person who archived this document. | TableRelation User."User Name"; not editable; DataClassification EndUserIdentifiableInformation |
| 5047 | Version No. | Integer | Specifies the version number of the archived document. |  |
| 5048 | Doc. No. Occurrence | Integer | — |  |
| 5050 | Campaign No. | Code[20] | Specifies the campaign number the document is linked to. | TableRelation [Table 5071 "Campaign"](../table/5071.md) |
| 5052 | Sell-to Contact No. | Code[20] | Specifies the number of the contact person at the customer's main address. | TableRelation [Table 5050 "Contact"](../table/5050.md) |
| 5053 | Bill-to Contact No. | Code[20] | Specifies the number of the contact person at the customer's billing address. | TableRelation [Table 5050 "Contact"](../table/5050.md) |
| 5054 | Bill-to Customer Template Code | Code[10] | Bill-to Customer Template Code (obsoleted) <small>caption</small> | obsolete Removed 25.0; #if not CLEANSCHEMA25 |
| 5055 | Opportunity No. | Code[20] | — | TableRelation Opportunity."No." where("Contact No." = field("Sell-to Contact No."), Closed = const(false)) |
| 5056 | Sell-to Customer Templ. Code | Code[20] | Specifies information about sales quotes, purchase quotes, or orders in earlier versions of the document | TableRelation [Table 1381 "Customer Templ."](../table/1381.md) (Customer Templ.) |
| 5057 | Bill-to Customer Templ. Code | Code[20] | Specifies information about sales quotes, purchase quotes, or orders in earlier versions of the document. | TableRelation [Table 1381 "Customer Templ."](../table/1381.md) (Customer Templ.) |
| 5700 | Responsibility Center | Code[10] | Specifies the code of the responsibility center (for example, a distribution center) assigned to the customer or associated with the order. | TableRelation [Table 5714 "Responsibility Center"](../table/5714.md) (Responsibility Center) |
| 5750 | Shipping Advice | Enum "Sales Header Shipping Advice" | Specifies the shipping advice, which informs whether partial deliveries are acceptable. | enum [Enum 3657 "Sales Header Shipping Advice"](../enum/3657.md) |
| 5752 | Completely Shipped | Boolean | — | FlowField: min("Sales Line Archive"."Completely Shipped" where("Document Type" = field("Document Type"), "Document No." = field("No."), "Version No." = field("Version No."), "Shipment Date" = field("Date Filter"), "Location Code" = field("Location Filter"))); not editable |
| 5753 | Posting from Whse. Ref. | Integer | — |  |
| 5754 | Location Filter | Code[10] | — | TableRelation [Table 14 "Location"](../table/14.md); FlowFilter |
| 5790 | Requested Delivery Date | Date | Specifies the date that your customer has asked for the order to be delivered. |  |
| 5791 | Promised Delivery Date | Date | Specifies the date that you have promised to deliver the order, as a result of the Order Promising function. |  |
| 5792 | Shipping Time | DateFormula | Specifies how long it takes from when the items are shipped from the warehouse to when they are delivered. |  |
| 5793 | Outbound Whse. Handling Time | DateFormula | Specifies a date formula for the time it takes to get items ready to ship from this location. The time element is used in the calculation of the delivery date as follows: Shipment Date + Outbound Warehouse Handling Time = Planned Shipment Date + Shipping Time = Planned Delivery Date. |  |
| 5794 | Shipping Agent Service Code | Code[10] | Specifies the code for the service, such as a one-day delivery, that is offered by the shipping agent. | TableRelation [Table 5790 "Shipping Agent Services"](../table/5790.md) ("Shipping Agent Services".Code where("Shipping Agent Code" = field("Shipping Agent Code"))) |
| 5795 | Late Order Shipping | Boolean | Indicates a delay in the shipment of one or more lines, or that the shipment date is either the same as or earlier than the work date. | FlowField: exist("Sales Line Archive" where("Document Type" = field("Document Type"), "Sell-to Customer No." = field("Sell-to Customer No."), "Document No." = field("No."), "Doc. No. Occurrence" = field("Doc. No. Occurrence"), "Version No." = field("Version No."), "Shipment Date" = field("Date Filter"))); not editable |
| 5796 | Date Filter | Date | — | FlowFilter |
| 5800 | Receive | Boolean | — |  |
| 5801 | Return Receipt No. | Code[20] | — |  |
| 5802 | Return Receipt No. Series | Code[20] | — | TableRelation [Table 308 "No. Series"](../table/308.md) (No. Series) |
| 5803 | Last Return Receipt No. | Code[20] | — | TableRelation [Table 6660 "Return Receipt Header"](../table/6660.md) (Return Receipt Header) |
| 7000 | Price Calculation Method | Enum "Price Calculation Method" | — | enum [Enum 7000 "Price Calculation Method"](../enum/7000.md) |
| 7001 | Allow Line Disc. | Boolean | — |  |
| 7200 | Get Shipment Used | Boolean | — | not editable |
| 9000 | Assigned User ID | Code[50] | Specifies the ID of the user who is responsible for the document. | TableRelation [Table 91 "User Setup"](../table/91.md) (User Setup); DataClassification EndUserIdentifiableInformation |

## Keys

- Key1: Document Type, No., Doc. No. Occurrence, Version No. (clustered)
- Key2: Document Type, Sell-to Customer No.
- Key3: Document Type, Bill-to Customer No.
- Key4: Incoming Document Entry No.

## Events published

- `OnBeforeSetSecurityFilterOnRespCenter(var SalesHeaderArchive: Record "Sales Header Archive"; var IsHandled: Boolean)` (integration): Raises an event before applying the security filter based on the user's responsibility center.

## Procedures

- `ShowDimensions()`: Opens the Dimension Set Entries page to display the dimensions associated with this archived sales header.
- `SetSecurityFilterOnRespCenter()`: Applies a security filter to restrict records based on the current user's assigned responsibility center.
- `GetWorkDescription(): Text`: Retrieves the work description text from the BLOB field as a readable text string.

## Triggers

OnDelete

## Relations

- drill-down page [Page 5161 "Sales List Archive"](../page/5161.md)
- lookup page [Page 5161 "Sales List Archive"](../page/5161.md)
- Shipment Method Code: TableRelation [Table 10 "Shipment Method"](../table/10.md)
- Last Shipping No.: TableRelation [Table 110 "Sales Shipment Header"](../table/110.md)
- Last Posting No.: TableRelation [Table 112 "Sales Invoice Header"](../table/112.md)
- Last Prepayment No.: TableRelation [Table 112 "Sales Invoice Header"](../table/112.md)
- Last Prepmt. Cr. Memo No.: TableRelation [Table 112 "Sales Invoice Header"](../table/112.md)
- Salesperson Code: TableRelation [Table 13 "Salesperson/Purchaser"](../table/13.md)
- Incoming Document Entry No.: TableRelation [Table 130 "Incoming Document"](../table/130.md)
- Bill-to Customer Templ. Code: TableRelation [Table 1381 "Customer Templ."](../table/1381.md)
- Sell-to Customer Templ. Code: TableRelation [Table 1381 "Customer Templ."](../table/1381.md)
- Location Code: TableRelation [Table 14 "Location"](../table/14.md)
- Location Filter: TableRelation [Table 14 "Location"](../table/14.md)
- Bal. Account No.: TableRelation [Table 15 "G/L Account"](../table/15.md) (conditional)
- Bill-to Customer No.: TableRelation [Table 18 "Customer"](../table/18.md)
- Sell-to Customer No.: TableRelation [Table 18 "Customer"](../table/18.md)
- Ship-to Code: TableRelation [Table 222 "Ship-to Address"](../table/222.md)
- Bill-to City: TableRelation [Table 225 "Post Code"](../table/225.md)
- Bill-to Post Code: TableRelation [Table 225 "Post Code"](../table/225.md)
- Sell-to City: TableRelation [Table 225 "Post Code"](../table/225.md)
- Sell-to Post Code: TableRelation [Table 225 "Post Code"](../table/225.md)
- Ship-to City: TableRelation [Table 225 "Post Code"](../table/225.md)
- Ship-to Post Code: TableRelation [Table 225 "Post Code"](../table/225.md)
- Reason Code: TableRelation [Table 231 "Reason Code"](../table/231.md)
- Gen. Bus. Posting Group: TableRelation [Table 250 "Gen. Business Posting Group"](../table/250.md)
- Transaction Type: TableRelation [Table 258 "Transaction Type"](../table/258.md)
- Transport Method: TableRelation [Table 259 "Transport Method"](../table/259.md)
- Bal. Account No.: TableRelation [Table 270 "Bank Account"](../table/270.md) (conditional)
- Company Bank Account Code: TableRelation [Table 270 "Bank Account"](../table/270.md)
- Exit Point: TableRelation [Table 282 "Entry/Exit Point"](../table/282.md)
- Area: TableRelation [Table 284 "Area"](../table/284.md)
- Transaction Specification: TableRelation [Table 285 "Transaction Specification"](../table/285.md)
- Payment Method Code: TableRelation [Table 289 "Payment Method"](../table/289.md)
- Shipping Agent Code: TableRelation [Table 291 "Shipping Agent"](../table/291.md)
- Payment Terms Code: TableRelation [Table 3 "Payment Terms"](../table/3.md)
- Prepmt. Payment Terms Code: TableRelation [Table 3 "Payment Terms"](../table/3.md)
- No. Series: TableRelation [Table 308 "No. Series"](../table/308.md)
- Posting No. Series: TableRelation [Table 308 "No. Series"](../table/308.md)
- Prepayment No. Series: TableRelation [Table 308 "No. Series"](../table/308.md)
- Prepmt. Cr. Memo No. Series: TableRelation [Table 308 "No. Series"](../table/308.md)
- Return Receipt No. Series: TableRelation [Table 308 "No. Series"](../table/308.md)
- Shipping No. Series: TableRelation [Table 308 "No. Series"](../table/308.md)
- Tax Area Code: TableRelation [Table 318 "Tax Area"](../table/318.md)
- VAT Bus. Posting Group: TableRelation [Table 323 "VAT Business Posting Group"](../table/323.md)
- Cust./Item Disc. Gr.: TableRelation [Table 340 "Customer Discount Group"](../table/340.md)
- Shortcut Dimension 1 Code: TableRelation [Table 349 "Dimension Value"](../table/349.md)
- Shortcut Dimension 2 Code: TableRelation [Table 349 "Dimension Value"](../table/349.md)
- Source Doc. Exists: CalcFormula [Table 36 "Sales Header"](../table/36.md)
- Sales Quote No.: TableRelation [Table 36 "Sales Header"](../table/36.md)
- Currency Code: TableRelation [Table 4 "Currency"](../table/4.md)
- Bill-to IC Partner Code: TableRelation [Table 413 "IC Partner"](../table/413.md)
- Sell-to IC Partner Code: TableRelation [Table 413 "IC Partner"](../table/413.md)
- Dimension Set ID: TableRelation [Table 480 "Dimension Set Entry"](../table/480.md)
- Bill-to Contact No.: TableRelation [Table 5050 "Contact"](../table/5050.md)
- Sell-to Contact No.: TableRelation [Table 5050 "Contact"](../table/5050.md)
- Campaign No.: TableRelation [Table 5071 "Campaign"](../table/5071.md)
- Last Archived Date: CalcFormula [Table 5107 "Sales Header Archive"](../table/5107.md)
- No. of Archived Versions: CalcFormula [Table 5107 "Sales Header Archive"](../table/5107.md)
- Amount: CalcFormula [Table 5108 "Sales Line Archive"](../table/5108.md)
- Amount Including VAT: CalcFormula [Table 5108 "Sales Line Archive"](../table/5108.md)
- Completely Shipped: CalcFormula [Table 5108 "Sales Line Archive"](../table/5108.md)
- Late Order Shipping: CalcFormula [Table 5108 "Sales Line Archive"](../table/5108.md)
- Comment: CalcFormula [Table 5126 "Sales Comment Line Archive"](../table/5126.md)
- Responsibility Center: TableRelation [Table 5714 "Responsibility Center"](../table/5714.md)
- Shipping Agent Service Code: TableRelation [Table 5790 "Shipping Agent Services"](../table/5790.md)
- Price Group Code: TableRelation [Table 6 "Customer Price Group"](../table/6.md)
- Last Return Receipt No.: TableRelation [Table 6660 "Return Receipt Header"](../table/6660.md)
- Language Code: TableRelation [Table 8 "Language"](../table/8.md)
- Bill-to Country/Region Code: TableRelation [Table 9 "Country/Region"](../table/9.md)
- Rcvd.-from Count./Region Code: TableRelation [Table 9 "Country/Region"](../table/9.md)
- Sell-to Country/Region Code: TableRelation [Table 9 "Country/Region"](../table/9.md)
- Ship-to Country/Region Code: TableRelation [Table 9 "Country/Region"](../table/9.md)
- VAT Country/Region Code: TableRelation [Table 9 "Country/Region"](../table/9.md)
- Assigned User ID: TableRelation [Table 91 "User Setup"](../table/91.md)
- Customer Posting Group: TableRelation [Table 92 "Customer Posting Group"](../table/92.md)

## Referenced by

7 fields in 5 objects relate to this table (TableRelation or CalcFormula).

- [Table 18 "Customer"](../table/18.md): Bill-to No. Of Archived Doc., Sell-to No. Of Archived Doc.
- [Table 5107 "Sales Header Archive"](../table/5107.md): Last Archived Date, No. of Archived Versions
- [Table 36 "Sales Header"](../table/36.md): No. of Archived Versions
- [Table 5108 "Sales Line Archive"](../table/5108.md): Document No.
- [Table 8069 "Sales Sub. Line Archive"](../table/8069.md): Document No.

## Pages and codeunits on this table

- [Page 30212 "APIV2 - Sales Qt. Archives"](../page/30212.md) (source table)
- [Page 30214 "APIV2 - Sales Ord. Archives"](../page/30214.md) (source table)
- [Page 30220 "APIV2 - S. Ret. Ord. Archives"](../page/30220.md) (source table)
- [Page 30228 "APIV2 - S. Bl. Ord. Archives"](../page/30228.md) (source table)
- [Page 5159 "Sales Order Archive"](../page/5159.md) (source table)
- [Page 5161 "Sales List Archive"](../page/5161.md) (source table)
- [Page 5162 "Sales Quote Archive"](../page/5162.md) (source table)
- [Page 6620 "Blanket Sales Order Archive"](../page/6620.md) (source table)
- [Page 6622 "Blanket Sales Order Archives"](../page/6622.md) (source table)
- [Page 6627 "Sales Return Order Archive"](../page/6627.md) (source table)
- [Page 6629 "Sales Return List Archive"](../page/6629.md) (source table)
- [Page 9348 "Sales Quote Archives"](../page/9348.md) (source table)
- [Page 9349 "Sales Order Archives"](../page/9349.md) (source table)
- [Codeunit 322 "SalesCount-PrintedArch"](../codeunit/322.md) (codeunit runs on it)

## Extended by

- [Table extension 30203 "Shpfy Sales Header Archive"](../tableextension/30203.md)

## Calls

From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an `Object::"Name"` argument. Interface dispatch and calls through events are not counted, so the list is not complete.

- [Codeunit 10 "Type Helper"](../codeunit/10.md) (2 calls: `GetWorkDescription → LFSeparator`, `GetWorkDescription → TryReadAsTextWithSepAndFieldErrMsg`)
- [Codeunit 408 "DimensionManagement"](../codeunit/408.md) (1 call: `ShowDimensions → ShowDimensionSet`)
- [Codeunit 5700 "User Setup Management"](../codeunit/5700.md) (1 call: `SetSecurityFilterOnRespCenter → GetSalesFilter`)
- [Codeunit 5703 "Catalog Item Management"](../codeunit/5703.md) (1 call: `OnDelete → DelNonStockSalesArch`)

## Across versions

- Present in: BC23-30
- Changed (declaration) in: BC24-28

## Countries that replace it

[AU](../../localizations/au.md), [BE](../../localizations/be.md), [CA](../../localizations/ca.md), [CH](../../localizations/ch.md), [IT](../../localizations/it.md), [MX](../../localizations/mx.md), [NO](../../localizations/no.md), [NZ](../../localizations/nz.md), [RU](../../localizations/ru.md), [US](../../localizations/us.md)

## Deprecations

- field Bill-to Customer Template Code: Removed 25.0 (#if not CLEANSCHEMA25), "Will be removed with other functionality related to "old" templates. Replaced by "Bill-to Customer Templ. Code"."

Source: AL metadata extracted from the code (names, ids, signatures, properties); no code bodies (D10).

## Ask your agent

Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: `bcatlas_resolve_node(object_type: "table", object_name: "Sales Header Archive")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
