SD BAPI RFC Used the same way in S/4HANA

BAPI_CUSTOMER_CREATEFROMDATA1 Create Customer from Reference (Online Store)

Creates a customer by copying a reference customer and sales area and adding personal or company data; SAP designed it for online store scenarios. It suits simple B2C registrations rather than full customer master migrations. In S/4HANA customers are maintained as business partners, so prefer the business partner APIs there; check RETURN and commit afterwards.

Function group
V02D
Remote-enabled (RFC)
Yes
Type
BAPI

Importing parameters

ParameterTypeDescriptionRequired
PI_PERSONALDATABAPIKNA101_1Personal data of the customerYes
PI_OPT_PERSONALDATABAPIKNA105Optional personal data—
PI_COMPANYDATABAPIKNA106Company (organization) data—
PI_OPT_COMPANYDATABAPIKNA105Optional company data—
PI_CONSUMERENBAPIKNA107-CONSUMER_FLAGConsumer flag—
PI_COPYREFERENCEBAPIKNA102Reference customer and sales area to copy fromYes
PI_CREDIT_CONTROL_FLAGBAPIKNA108-X_FLAGCredit control flag—

Exporting parameters

ParameterTypeDescription
CUSTOMERNOBAPIKNA103-CUSTOMERCustomer number created
RETURNBAPIRETURN1Return messages

Call template (ABAP)

A skeleton generated from the interface. It lists mandatory importing parameters, exporting parameters and tables; declare the variables with suitable types in your own program.

CALL FUNCTION 'BAPI_CUSTOMER_CREATEFROMDATA1'
  EXPORTING
    pi_personaldata = lv_pi_personaldata
    pi_copyreference = lv_pi_copyreference
  IMPORTING
    customerno = lv_customerno
    return = lv_return.

Related tables

Can't find the report you need?

We also build anything that is not in the catalog. Describe it briefly and we will suggest the right solution.

Request a custom report