Quick answer

How to upload customer master data from Excel: XD01 or BP

On SAP ECC, PostNow.ai uploads customer master data from Excel by replaying an XD01 recording, one customer per row, and writes the new customer number back. On S/4HANA, XD01 redirects to transaction BP, which does not support batch input, so PostNow.ai creates the business partner with BAPI_BUPA_CREATE_FROM_DATA; customer roles go through an interface listed in SAP Note 2417298.

  • ECC: one XD01 template per account group and screen path, then a second template for further sales areas.
  • S/4HANA: business partner first, then customer roles FLCU00 (company code) and FLCU01 (sales).

Most customer loads that go wrong have valid data. They used the wrong account group, a number range nobody checked, or a customer that already existed under a slightly different name. This page covers those decisions first and the mechanics second. For choosing a method across all SAP objects, see SAP mass upload from Excel.

How PostNow.ai uploads customer master data from Excel

PostNow.ai treats an ECC customer upload as a recorded transaction. A designer records XD01 once, and every Excel row replays that recording through CALL TRANSACTION, so SAP runs the same field-status, number-range and sales-area checks it runs for a person at the keyboard.

1. Record XD01 for one account group

Press Record on the PostNow.ai ribbon and create one real customer in a test client. On the initial screen (SAPMF02D 0100) you enter the account group (RF02D-KTOKD), company code (RF02D-BUKRS) and the sales area (RF02D-VKORG, RF02D-VTWEG, RF02D-SPART). Then walk every screen the customer needs, from address to partner functions, and save. The recording runs through SHDB, so you see each screen, field and OK-code it captured.

Check: a screen you skipped while recording is a screen the upload will never reach.

2. Map columns, and fix what should not vary

In the Mapping Designer each recorded field becomes an Excel column, a fixed value or a system value. Make the account group a fixed value, because the account group decides which screens and fields exist. If the whole file belongs to one company code and sales area, fix those too, so the file carries only what differs per customer.

3. Restrict the values that drive SAP's behaviour

Give country, reconciliation account, payment terms and customer pricing procedure a value list, from SAP's check table or typed by you, and switch on Restrict to make it a hard allow-list at Validate. Opt-in Pre-Validation also asks SAP whether each value exists in its check table.

4. Simulate and Debug a few customers

For XD01, PostNow.ai's Simulate strips the save and walks the screens. That still catches screen-level errors, such as a sales area SAP rejects. Debug replays rows in the foreground in SAP GUI, either every screen or only the screens with errors. Debug a few customers from different countries, then look at them in XD03.

5. Run, and write the customer number back

Run posts each row under your own SAP login and writes SAP's message to that row's Run Log. Map the message variable that carries the new number to a column, so the customer number sits next to the source row. Retry Failed re-posts only rows whose Run Log starts with ERROR, scanning from the current Start Row. A second Run on the same sheet first lists the rows that already show a success and offers Skip posted rows, Post again or Cancel, which matters here: posting a row again creates a second customer.

Recording rules that make a replay reliable are in the BDC recording guide. If this is your first upload of any kind, how to upload data into SAP from Excel walks through one file end to end.

XD01 in SAP ECC vs Business Partner in S/4HANA

PostNow.ai uses a different route per release, because SAP changed the object. On ECC the customer is the master record. On S/4HANA the business partner is, and the customer is a set of roles that CVI keeps in step with it.

SAP ECCSAP S/4HANA
PostNow.ai routeXD01 recording, one template per account group, optional second template for more sales areasBAPI_BUPA_CREATE_FROM_DATA in BAPI mode for the business partner; customer roles and segments through an interface your SAP team provides (see the next section)
Where you maintain itXD01 (central), FD01 (general and company code), VD01 (general and sales area)Transaction BP. XD01, XD02 and XD03 redirect to BP.
What controls numbering and fieldsAccount group: number range, field status, one-time accountBP grouping for the BP number range, linked to a customer account group for the customer number
Company code dataKNB1Role FLCU00, stored in KNB1
Sales area dataKNVV, partner functions in KNVPRole FLCU01, stored in KNVV and KNVP
Link between the objectsNone neededCVI_CUST_LINK (business partner GUID to customer number)

What happens when you call XD01 in S/4HANA. SAP sends you to BP, which its conversion guide calls the single point of entry for business partners, customers and suppliers.

Why not record BP instead? SAP knowledge base article 1951318 says batch input and eCATT are not supported in transaction BP. PostNow.ai can record it, but an unsupported recording is a fragile thing to hand to operators.

S/4HANA business partners only? If the job is BP itself (groupings, roles, the supplier and customer sides together), the SAP Business Partner automation from Excel guide covers it with PostNow.ai end to end.

BAPI or recording: which customer master API to use

PostNow.ai's BAPI mode can call any RFC-enabled function module by name, and it reads SAP's verdict from a parameter called RETURN, whether that is a table or a single structure. That decides which interfaces fit.

RouteReleaseWhat it createsWatch out for
PostNow.ai: XD01 recording from ExcelECCGeneral data, one company code and one sales area per save, with whatever the recorded screens containOne template per account group and screen path; a changed screen layout means re-recording
PostNow.ai: BAPI_BUPA_CREATE_FROM_DATAS/4HANAThe business partner: category, grouping, central data, name and address, communication dataCovers the central data; customer roles, company code and sales area data come from a CVI interface in Note 2417298
BAPI_CUSTOMER_CREATEFROMDATA1ECCA customer copied from a reference customer and sales area (PI_COPYREFERENCE), with personal or company address dataSAP's own short text reads "Only for ONLINE Store". It is built for consumers, not for B2B customers with their own company code data
CL_MD_BP_MAINTAINS/4HANABusiness partner with customer roles, company code and sales area data, through CVIAn ABAP class, not an RFC function. To call it from Excel, your developers wrap it in an RFC-enabled Z function module with a RETURN parameter. Mind KBA 2850047 on partner functions
Migration Cockpit object CustomerS/4HANAComplete customers from SAP's migration template, with a separate object to extend existing customers by new organisational levelsA migration tool for projects, run by the migration team, not a daily upload for operators
IDoc DEBMASECC and S/4HANACustomers sent from another systemInterface work for IT. SAP points S/4HANA-to-S/4HANA business partner integration to its web services instead

A trap in BAPI search. Search for "create customer" and BAPI_CUSTOMER_CREATEFROMDATA1 comes up first in PostNow.ai's Find with AI. Read its short text first; for business customers on ECC, the XD01 recording is the better route.

What SAP recommends on S/4HANA. SAP Note 2417298, "Integration of Business Partner with Customer and Supplier Roles", lists the interfaces SAP releases for this. Do not build on RFC_CVI_EI_INBOUND_MAIN: KBA 2650140 says it is not supported from S/4HANA 1709 FPS2 on. The general trade-off between the two methods is in BAPI vs BDC in SAP.

Account groups, number ranges and mandatory fields

In PostNow.ai the account group is a fixed value of the template, because it changes the screens the recording walks through. Four things hang off it.

  • The number range. The account group carries the number range, and the number range decides whether SAP assigns the customer number (internal) or your file must supply it (external). With external numbering the number is a column; with internal numbering you leave it empty and write SAP's number back.
  • Field status, which is where "mandatory fields" come from. The account group sets each field to suppressed, optional or required. Field status can also depend on the company code and on the transaction, so the same field can be required in one company code and hidden in another. Mark the required columns from your own configuration, not from another system's list.
  • Which screens exist. A field the account group suppresses is not on the screen. A recording made with one account group and replayed with another sends values into fields that are not there, and batch input reports 00 349. PostNow.ai flags this "field does not exist on screen" message, because it means data was silently dropped.
  • Partner functions. The partner determination procedure assigned to the account group decides which partner functions a customer needs. For a sold-to party, SAP fills ship-to, bill-to and payer with the sold-to's own number by default. If a mandatory partner function is missing in the customer master, SAP Help says the order stays incomplete until someone enters it.

On S/4HANA, two numbers. The BP grouping determines the business partner number range, and the customer account group determines the customer number range. CVI links the two in Customizing (Define Number Assignment for Direction BP to Customer). If BP and customer should share one number, SAP's conversion guide explains how the ranges must fit for the "same numbers" setting. Decide it before the first load.

On S/4HANA, field status has more sources. The BP role, the BP grouping and the customer account group all carry field status settings. If a field is unexpectedly required or hidden, check all three before you change the template.

Company code and sales area views: one save, one sales area

PostNow.ai replays XD01 the way it was recorded, and the XD01 initial screen takes one company code and one sales area. That gives every multi-area load the same shape.

  • The sales area is one key. Sales organisation, distribution channel and division are checked as a combination. Three valid values can still form a combination that is not defined for customers, and SAP answers F2 644. Pre-Validation checks each value on its own, so the combination is something you check in Simulate or Debug.
  • A second sales area is a second run. Create the customers with the first sales area, let the Run Log write the numbers back, then run a second template (VD01, or XD01 with the existing number and the new sales area) for the extensions. PostNow.ai chains run on BAPI templates; with recordings, plan these as two runs.
  • A second company code works the same way. FD01, or XD01 with the existing number and the new company code. The reconciliation account must be valid in that company code, or SAP answers F2 068.
  • Partner functions point to customers that must already exist. SAP requires a master record for every partner you enter. Load payers and ship-tos that belong to other customers first, then the sold-to parties that reference them.
SAP sales area built from sales organisation, distribution channel and division, with the sold-to, ship-to, bill-to and payer partner functions of a customer
Diagram The sales area is the combination of sales organisation, distribution channel and division. Partner functions are kept per sales area, in KNVP.

Duplicate check before a customer master upload

SAP creates a new customer for every row it accepts, even when the same company already exists under another number. Do the duplicate check in Excel before the run, against SAP and against the file itself.

  1. Pull what exists. In the PostNow.ai Report Library, Duplicate Customers (W-12) groups KNA1 by name, tax number 1 and country, and Customer Master Sales 360 (SD-01) lists customers with sales areas, partner functions and reconciliation account. Operators can run both, under their own SAP authorisations.
  2. Match on more than the name. Normalise the name (legal form, punctuation, spacing), then compare tax number, postcode and street with COUNTIFS against the extract. A tax number match is strong evidence; a name match alone is a question for a person.
  3. Check the file against itself. Two rows for the same new customer pass every SAP check and give you two numbers. The same COUNTIFS on the file catches them.
  4. Remove or mark rows before Validate. If the match exists only in another sales area, the row belongs in the extension template.

SAP's own checks. S/4HANA can warn about likely duplicate business partners from the address index, as a pop-up for the person creating the partner. That is a prompt for someone at the screen, so treat it as a second line, not your check.

Who may request, approve and own a new customer is a governance question; SAP master data governance covers owners, approvals and audit with or without SAP MDG.

Worked example: 40 new sold-to customers in company code 1010

PostNow.ai handles this with one XD01 template and one run, on an ECC system with internal numbering. Sales sends 40 new trade customers for company code 1010, sales area 1010 / 10 / 00, account group 0001.

  1. Check for duplicates. W-12 and SD-01 go into the workbook. Tax numbers match on two rows: customer 200371 already exists in sales area 1010/10/00, and a second customer exists only in sales organisation 1020. The first row is removed. The second moves to the extension file for a later run. Two rows in the file share a tax number; Sales confirms they are the same company, and one row is deleted.
  2. Build the template. Account group 0001, company code 1010 and the sales area are fixed values. Reconciliation account, payment terms and customer pricing procedure have allow-lists with Restrict on. Name, country, postcode and tax number are required columns, matching the field status of 0001.
  3. Validate. One row has no name, one tax number is longer than the field, and one payment term is not on the allow-list. They are fixed in Excel and Validate is clean.
  4. Debug three rows. A German, a French and a US customer, all screens in the foreground. XD03 shows the right reconciliation account, and sold-to, ship-to, bill-to and payer all point to the customer itself.
  5. Approve and run. If an approval policy covers the template, Run waits until someone other than the submitter approves, and an edit after approval cancels it. Run creates the remaining customers and fills the number column.
  6. Hand back. Sales gets the workbook with a customer number on every row. With Call Transaction set to XD03, a click on a number opens that customer in display mode.
⚠
Load into a quality client first. A created customer cannot be uncreated. Stop cancels the rows not yet sent, and customers already saved stay in SAP. A wrong one is blocked or flagged for deletion, and its number is gone from the range.

Checklist before a customer master upload

PostNow.ai enforces the formats and allow-lists in the template; this list covers the decisions that stay with the master data team.

  • You know whether the number range is internal or external, and external numbers in the file are unique and inside the range.
  • Required columns match the field status of the account group, company code and transaction in the target system, not in a sandbox.
  • The sales area combination is valid for customers, and Simulate on a few rows has shown no F2 644.
  • Customers referenced as payer, bill-to or ship-to already exist and are extended to the sales area.
  • The file has been checked against W-12 / SD-01 and against itself for duplicates.
  • On S/4HANA: grouping, account group and number assignment are maintained, and the interface for company code and sales area data is agreed.
  • A few rows have run in Debug in a quality client, and XD03 or BP shows what you expected.

How to check customer master data after the upload

PostNow.ai gives you the first check per row: the Run Log holds SAP's message and the customer number, and the central audit records each row's transaction, template, SAP system, client, user and result. The rest of the proof comes from SAP.

  • Tables on ECC. General data in KNA1, company code data in KNB1, sales area data in KNVV, partner functions in KNVP. Count the new rows per table; 40 customers with one company code and one sales area give 40 rows in each of the first three.
  • On S/4HANA, the link as well. BUT000 holds the business partner and CVI_CUST_LINK links it to the customer number. A business partner without a link row has no customer. Synchronisation errors between BP and customer are in the post-processing office, transaction MDS_PPO2.
  • Display a sample. XD03 on ECC, BP on S/4HANA, across countries and account groups.
  • Report Library. Customer Master Sales 360 (SD-01), filtered on creation date, lists the new customers with their sales area data in Excel. The SAP customer master report explains which general, company code and sales-area fields to pull.
  • A test order. One VA01 order per account group in the quality client. Partner determination, pricing and tax only show up there.
  • The Run Log is final. PostNow.ai runs recordings with synchronous update, so each row's messages and customer number return at once in the Run Log.
The layers of an SAP customer master: general data in KNA1, company code data in KNB1, sales area data in KNVV, partner functions in KNVP, and credit set-up
Diagram The layers a usable customer needs. Count each one after a load; a customer number alone proves only the first.

Credit limits are a separate object. On ECC they are FD32, and that load is covered in bulk credit-limit updates.

Common customer upload errors and the fix

PostNow.ai writes SAP's message to the row it belongs to, so the fix starts from the message.

MessageWhat it meansFix
F2 644 Sales area &1 &2 &3 is not defined for customersThe combination is missing in TVTA, or it refers to another sales area for customer dataIn XD01 use Extras, Sales areas, All areas to see valid combinations; restrict the three columns to those
F2 007 Account &1 already existsWith external numbering, the number is taken. With internal numbering, KBA 2923061 traces it to a number range at or near its highest numberCheck the file against KNA1; check the number range status before the run
F2 068 Account &1 is an invalid reconciliation account in company code &2The G/L account is not set up as a customer reconciliation account in that company codeAllow-list the reconciliation account per company code
00 349 Field does not exist on the screenThe recording sends a field the screen does not show, often because the row's account group suppresses itKeep one template per account group; PostNow.ai flags these drops
Role FLCU00 / FLCU01 not maintained (S/4HANA)Company code or sales data was sent for a business partner without the customer roleAdd the customer roles before or with the company code and sales area data (KBA 2736246)

What to plan for in a customer master upload

PostNow.ai replays XD01 as recorded and calls BAPIs as SAP defines them, so SAP's own customer master rules decide every result.

  • Prove combinations in Simulate or Debug. Pre-Validation confirms that each value exists in SAP. Whether the sales area combination and the reconciliation account fit the company code, SAP decides in Simulate, Debug and Run.
  • Plan an RFC wrapper for order-ready S/4HANA customers. BAPI_BUPA_CREATE_FROM_DATA creates the business partner. Company code and sales area data come from an interface listed in Note 2417298, which your SAP team wraps for RFC.
  • Run the duplicate check on every new file. The re-run guard reads the Run Log and protects a second Run on the same sheet. A new file with the same customers starts with an empty Run Log, so your duplicate check is what catches them.
  • Correct created customers in SAP. Stop cancels the rows not yet sent; created customers stay in SAP, and a wrong one is blocked or flagged for deletion there.
  • Plan a person to start each run. Recording templates run when a user starts them in Excel.
  • Keep the PostNow.ai portal reachable for approved templates. The approval check runs against the portal; if the portal cannot be reached, the check lets the run through.

Making a template like this repeatable for a team (designers who record, operators who only run, a published template in the central library) is the subject of Excel to SAP automation. Orders for the new customers are covered in VA01 mass sales order creation, and the vendor side in XK01 vendor master upload. Where customers sit in the full SD load order (customers, prices, orders, deliveries, billing) is in SAP SD mass upload.

Frequently asked questions

How do I upload customer master data from Excel into SAP?
With PostNow.ai on ECC you record XD01 once per account group, with one company code and one sales area, and map the Excel columns to the recorded fields. Validate checks formats, required columns and allowed values, and Debug replays a few customers in SAP GUI. Run creates one customer per row under your own SAP login and writes SAP's message and the new customer number back to the row. On S/4HANA the route goes through Business Partner interfaces instead.
Does the XD01 tcode still work in SAP S/4HANA?
Not as its own screens. In S/4HANA, XD01, XD02 and XD03 redirect to transaction BP, which SAP calls the single point of entry for business partners, customers and suppliers. The customer data still exists in KNA1, KNB1 and KNVV, kept in step with the business partner by Customer/Vendor Integration (CVI).
Which BAPI creates a customer master in SAP?
On ECC, BAPI_CUSTOMER_CREATEFROMDATA1 exists, but it copies a reference customer and its short text says it is only for online store use, so B2B customers are better loaded through an XD01 recording. On S/4HANA, BAPI_BUPA_CREATE_FROM_DATA creates the business partner's central data and address, but not the customer roles, company code or sales area data. SAP Note 2417298 lists the interfaces SAP releases for business partners with customer roles.
Can I use a BDC recording of transaction BP?
SAP says no: KBA 1951318 states that batch input and eCATT are not supported in transaction BP, which runs on the Business Data Toolset. PostNow.ai can record BP like any other transaction, but an unsupported recording is a fragile thing to hand to operators. Use one of the released BP interfaces listed in SAP Note 2417298 instead.
What does the account group control in the customer master?
The customer account group (KTOKD) controls the number range, and with it whether SAP assigns the customer number or the file must supply it. It also sets the field status, deciding which fields are hidden, optional or required, and whether the account is a one-time account. The partner determination procedure assigned to it decides which partner functions the customer needs.
How do I avoid duplicate customers in a mass upload?
Check the file before the run, against SAP and against itself. In PostNow.ai the Duplicate Customers report (W-12) groups existing customers by name, tax number and country, and Customer Master Sales 360 (SD-01) lists their sales areas. Match on tax number, postcode and street rather than name alone, and send name-only matches to a person. When a second Run starts on the same sheet, PostNow.ai offers to skip rows that already show a success.
Why do I get "Sales area is not defined for customers" (F2 644)?
The combination of sales organisation, distribution channel and division is not defined in TVTA, or it points to another sales area for customer data. Each of the three values can be valid on its own and still fail as a combination. In XD01, Extras, Sales areas, All areas lists the valid combinations; restrict the template's columns to those.
How do I check customer master data after an upload?
Start with PostNow.ai's Run Log, which holds SAP's message and the customer number per row. Then count new rows in KNA1, KNB1, KNVV and KNVP, display a sample in XD03 (ECC) or BP (S/4HANA), and on S/4HANA check that CVI_CUST_LINK links every new business partner to a customer.
One template per account group

Load your next customer file into SAP

Map the general, company code and sales area data once, check every row before it saves, and get each new customer number back on its row.

Start free trial
  • 14-day free trial
  • Works with ECC and S/4HANA
  • Your data stays in your systems