‎2007 Dec 23 9:37 AM
Hi All,
I am having problem finding a right bapi for create a customer.
I am using "bapi_customer_createfromdata1" to create a customer. Problem is i couldn't find a structure to pass sales org. data as well as partner functions.
Please help me. Feel free to ask me questions.
Thanks,
Diwakar.
‎2007 Dec 24 2:28 PM
Hi,
The way is using multiple BAPI's.
bapi "bapi_customer_createfromdata1" is used to create customer with reference customer number and then send the information to bapi "sd_customer_maintain_all" for changing the the values.
Still having problem passing parameters.
When i am sending partner information(knvp) to "sd_customer_maintain_all", it is giving abap dump assertion_failed.
I tried to debug the program but i couldn't find the error.
values i passed to bapi sd_customer_maintain_all
internal table of type <b>fknvp</b>.
MANDT sy-mandt
KUNNR st_knvp-kunnr
VKORG st_knvp-vkorg
VTWEG st_knvp-vtweg
SPART st_knvp-spart
PARVW st_knvp-parvw
PARZA
KUNN2 st_knvp-sp_kunnr
LIFNR
PERNR
PARNR
KNREF
DEFPA
Appended line by line to the table.
Reward points if found helpful....
Cheers,
Venkoji Babu.
‎2007 Dec 23 11:40 PM
Hello Reddy
The BAPI creates the new customer based on a template customer. Most of the business-related data are copied from this reference customer which you have to provide in the mandatory IMPORTING parameter PI_COPYREFERENCE. This structure contains the reference customer and the sales area:
SALESORG Sales Organization
DISTR_CHAN Distribution Channel
DIVISION Division
REF_CUSTMR Reference customer
The reference customer must exist in the sales area. The new customer will be created in the same sales area.
Kind Regards,
Uwe
‎2007 Dec 24 2:28 PM
Hi,
The way is using multiple BAPI's.
bapi "bapi_customer_createfromdata1" is used to create customer with reference customer number and then send the information to bapi "sd_customer_maintain_all" for changing the the values.
Still having problem passing parameters.
When i am sending partner information(knvp) to "sd_customer_maintain_all", it is giving abap dump assertion_failed.
I tried to debug the program but i couldn't find the error.
values i passed to bapi sd_customer_maintain_all
internal table of type <b>fknvp</b>.
MANDT sy-mandt
KUNNR st_knvp-kunnr
VKORG st_knvp-vkorg
VTWEG st_knvp-vtweg
SPART st_knvp-spart
PARVW st_knvp-parvw
PARZA
KUNN2 st_knvp-sp_kunnr
LIFNR
PERNR
PARNR
KNREF
DEFPA
Appended line by line to the table.
Reward points if found helpful....
Cheers,
Venkoji Babu.