---
title: "Codeunit 6112 Customer Data Migration Facade"
author: "Jonas Paprotka"
url: https://jonas-paprotka.de/ref/codeunit/6112-customer-data-migration-facade/
type: codeunit
id: 6112
name: "Customer Data Migration Facade"
app: "Base Application"
namespace: System.Integration
versions: "17-28"
build: 28.5.54151.54365
source: "https://jonas-paprotka.de/ref/codeunit/6112-customer-data-migration-facade/source/29/"
checked: 2026-09-20
subject: "Microsoft Dynamics 365 Business Central"
license: "Content © 2026 Jonas Paprotka. Quote freely with attribution and a link."
---

# Codeunit 6112 Customer Data Migration Facade

Jonas Paprotka, https://jonas-paprotka.de/ref/codeunit/6112-customer-data-migration-facade/

| | |
| --- | --- |
| App | Base Application |
| Namespace | System.Integration |
| Versions | 17-28 |
| Source file | System/DataMigration/CustomerDataMigrationFacade.Codeunit.al |

## Procedures

| Name | Parameters | Returns | Access | Versions | Obsolete | Reason |
| --- | --- | --- | --- | --- | --- | --- |
| CreateCustomerIfNeeded | (Code[20], Text[50]) | Boolean | public | 17-26 | - | - |
| CreatePostingSetupIfNeeded | (Code[20], Text[50], Code[20]) | - | public | 17-28 | - | - |
| CreateGeneralJournalBatchIfNeeded | (Code[10], Code[20], Code[20]) | - | public | 17-28 | - | - |
| CreateGeneralJournalLine | (Code[10], Code[20], Text[50], Date, Date, Decimal, Decimal, Code[10], Code[20]) | - | public | 17-28 | - | - |
| SetGeneralJournalLineDimension | (Code[20], Text[50], Code[20], Text[50]) | - | public | 17-28 | - | - |
| SetGeneralJournalLineDocumentType | (Option) | - | public | 17-28 | - | - |
| SetGeneralJournalLineSourceCode | (Code[10]) | - | public | 17-28 | - | - |
| SetGeneralJournalLineExternalDocumentNo | (Code[35]) | - | public | 17-28 | - | - |
| SetGeneralJournalLineSalesPersonCode | (Code[20]) | - | public | 17-28 | - | - |
| SetGeneralJournalLinePaymentTerms | (Code[10]) | - | public | 17-28 | - | - |
| SetGlobalCustomer | (Code[20]) | Boolean | public | 17-28 | - | - |
| ModifyCustomer | (Boolean) | - | public | 17-28 | - | - |
| SetSearchName | (Code[50]) | - | public | 17-28 | - | - |
| DoesCustomerExist | (Code[20]) | Boolean | public | 17-28 | - | - |
| SetAddress | (Text[50], Text[50], Code[10], Code[20], Text[30]) | - | public | 17-28 | - | - |
| SetPhoneNo | (Text[30]) | - | public | 17-28 | - | - |
| SetTelexNo | (Text[20]) | - | public | 17-28 | - | - |
| SetCreditLimitLCY | (Decimal) | - | public | 17-28 | - | - |
| SetCurrencyCode | (Code[10]) | - | public | 17-28 | - | - |
| SetCustomerPriceGroup | (Code[10]) | - | public | 17-28 | - | - |
| SetGenBusPostingGroup | (Code[10]) | - | public | 17-28 | - | - |
| SetLanguageCode | (Code[10]) | - | public | 17-28 | - | - |
| SetShipmentMethodCode | (Code[10]) | - | public | 17-28 | - | - |
| SetPaymentTermsCode | (Code[10]) | - | public | 17-28 | - | - |
| SetSalesPersonCode | (Code[20]) | - | public | 17-28 | - | - |
| SetInvoiceDiscCode | (Code[20]) | - | public | 17-28 | - | - |
| SetBlocked | (Enum Customer Blocked) | - | public | 17-28 | - | - |
| SetBlockedType | (Option) | - | public | 17-19 | Pending 17.0 | Replaced by procedure SetBlocked with enum data type. |
| SetFaxNo | (Text[30]) | - | public | 17-28 | - | - |
| SetVATRegistrationNo | (Text[20]) | - | public | 17-28 | - | - |
| SetHomePage | (Text[80]) | - | public | 17-28 | - | - |
| SetBillToCustomerNo | (Code[20]) | - | public | 17-28 | - | - |
| SetPaymentMethodCode | (Code[10]) | - | public | 17-28 | - | - |
| SetContact | (Text[50]) | - | public | 17-28 | - | - |
| SetLastDateModified | (Date) | - | public | 17-28 | - | - |
| SetLastModifiedDateTime | (DateTime) | - | public | 17-28 | - | - |
| SetTaxLiable | (Boolean) | - | public | 17-28 | - | - |
| SetTaxAreaCode | (Code[20]) | - | public | 17-28 | - | - |
| SetEmail | (Text[80]) | - | public | 17-28 | - | - |
| SetName2 | (Text[50]) | - | public | 17-28 | - | - |
| SetTerritoryCode | (Code[10]) | - | public | 17-28 | - | - |
| SetPrintStatement | (Boolean) | - | public | 17-28 | - | - |
| CreateDefaultDimensionAndRequirementsIfNeeded | (Text[20], Text[50], Code[20], Text[30]) | - | public | 17-26 | - | - |
| CreateCustomerDiscountGroupIfNeeded | (Code[20], Text[50]) | Code[20] | public | 17-28 | - | - |
| CreateShipmentMethodIfNeeded | (Code[10], Text[50]) | Code[10] | public | 17-28 | - | - |
| CreateSalespersonPurchaserIfNeeded | (Code[20], Text[50], Text[30], Text[80]) | Code[20] | public | 17-28 | - | - |
| CreateCustomerPriceGroupIfNeeded | (Code[10], Text[50], Boolean) | Code[10] | public | 17-28 | - | - |
| CreatePaymentTermsIfNeeded | (Code[10], Text[50], DateFormula) | Code[10] | public | 17-28 | - | - |
| CreatePaymentMethodIfNeeded | (Code[10], Text[50]) | Code[10] | public | 17-28 | - | - |
| CreateTerritoryCodeIfNeeded | (Code[10], Text[50]) | Code[10] | public | 17-28 | - | - |
| CreateTaxAreaIfNeeded | (Code[20], Text[50]) | Code[20] | public | 17-28 | - | - |
| DoesPostCodeExist | (Code[20], Text[30]) | Boolean | public | 17-28 | - | - |
| CreatePostCodeIfNeeded | (Code[20], Text[30], Text[30], Code[10]) | Boolean | public | 17-28 | - | - |
| CreateCountryIfNeeded | (Code[10], Text[50], Option, Option) | Code[10] | public | 17-28 | - | - |
| SearchCountry | (Code[10], Text[50], Code[10], Code[10], var Code[10]) | Boolean | public | 17-28 | - | - |
| SearchLanguage | (Code[3], var Code[10]) | Boolean | public | 17-28 | - | - |
| SetCustomerPostingGroup | (Code[20]) | Boolean | public | 17-28 | - | - |
| SetCustomerPostingGroupAccounts | (Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupServiceChargeAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupPaymentDiscDebitAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupInvoiceRoundingAccount | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupAdditionalFeeAccount | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupInterestAccount | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupDebitCurrApplnRndgAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupCreditCurrApplnRndgAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupDebitRoundingAccount | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupCreditRoundingAccount | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupPaymentDiscCreditAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupPaymentToleranceDebitAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupPaymentToleranceCreditAcc | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerPostingGroupAddFeePerLineAccount | (Code[20], Code[20]) | - | public | 17-28 | - | - |
| SetCustomerAlternativeContact | (Text[50], Text[50], Text[50], Code[20], Text[30], Code[10], Text[80], Text[30], Text[30], Text[30]) | - | public | 17-28 | - | - |
| CreateCustomerIfNeeded | (Code[20], Text[100]) | Boolean | public | 27-28 | - | - |
| CreateDefaultDimensionAndRequirementsIfNeeded | (Text[20], Text[50], Code[20], Text[50]) | - | public | 27-28 | - | - |

## Events

| Kind | Name | Parameters | Versions | Obsolete | Reason |
| --- | --- | --- | --- | --- | --- |
| Integration event | OnMigrateCustomer | (RecordId) | 17-28 | - | - |
| Integration event | OnMigrateCustomerDimensions | (RecordId) | 17-28 | - | - |
| Integration event | OnMigrateCustomerPostingGroups | (RecordId, Boolean) | 17-28 | - | - |
| Integration event | OnMigrateCustomerTransactions | (RecordId, Boolean) | 17-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.
