Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Problem while creating contact person using SD_CUSTOMER_MAINTAIN_ALL

Hi All,

I am trying to create a contact person to a customer using FM SD_CUSTOMER_MAINTAIN_ALL.Following is the simple code that I am using.FM is not giving any exception.But the contact person is not getting created.can anyone help me regarding this.

DATA: I_FKNVK TYPE TABLE OF FKNVK,

wa type FKNVK.

MOVE '0009011357' to wa-kunnr.

MOVE 'Bose' TO wa-namev.

MOVE 'Lalit' TO wa-name1.

MOVE '9980055557' to wa-TELF1.

*MOVE 'City' TO wa-ort01.

*MOVE 'DE' TO wa-parla.

*MOVE '' to watelf1.

*MOVE 'U' to wa-kz.

APPEND wa to I_FKNVK.

CALL FUNCTION 'SD_CUSTOMER_MAINTAIN_ALL'

EXPORTING

  • I_KNA1 =

  • I_KNB1 =

  • I_KNVV =

  • I_BAPIADDR1 =

  • I_BAPIADDR2 =

  • I_MAINTAIN_ADDRESS_BY_KNA1 = ' '

  • I_KNB1_REFERENCE = ' '

  • I_FORCE_EXTERNAL_NUMBER_RANGE = ' '

  • I_NO_BANK_MASTER_UPDATE = ' '

  • I_CUSTOMER_IS_CONSUMER = ' '

  • I_RAISE_NO_BTE = ' '

PI_POSTFLAG = 'X'

  • PI_CAM_CHANGED = ' '

  • PI_ADD_ON_DATA =

  • I_FROM_CUSTOMERMASTER = ' '

  • IMPORTING

  • E_KUNNR =

  • O_KNA1 =

  • E_SD_CUST_1321_DONE =

TABLES

  • T_XKNAS =

  • T_XKNBK =

  • T_XKNB5 =

  • T_XKNEX =

  • T_XKNVA =

  • T_XKNVD =

  • T_XKNVI =

T_XKNVK = I_FKNVK

  • T_XKNVL =

  • T_XKNVP =

  • T_XKNZA =

  • T_YKNAS =

  • T_YKNBK =

  • T_YKNB5 =

  • T_YKNEX =

  • T_YKNVA =

  • T_YKNVD =

  • T_YKNVI =

  • T_YKNVK =

  • T_YKNVL =

  • T_YKNVP =

  • T_YKNZA =

  • T_UPD_TXT =

EXCEPTIONS

CLIENT_ERROR = 1

KNA1_INCOMPLETE = 2

KNB1_INCOMPLETE = 3

KNB5_INCOMPLETE = 4

KNVV_INCOMPLETE = 5

KUNNR_NOT_UNIQUE = 6

SALES_AREA_NOT_UNIQUE = 7

SALES_AREA_NOT_VALID = 8

INSERT_UPDATE_CONFLICT = 9

NUMBER_ASSIGNMENT_ERROR = 10

NUMBER_NOT_IN_RANGE = 11

NUMBER_RANGE_NOT_EXTERN = 12

NUMBER_RANGE_NOT_INTERN = 13

ACCOUNT_GROUP_NOT_VALID = 14

PARNR_INVALID = 15

BANK_ADDRESS_INVALID = 16

TAX_DATA_NOT_VALID = 17

NO_AUTHORITY = 18

COMPANY_CODE_NOT_UNIQUE = 19

DUNNING_DATA_NOT_VALID = 20

KNB1_REFERENCE_INVALID = 21

CAM_ERROR = 22

OTHERS = 23

.

IF sy-subrc <> 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'

EXPORTING

WAIT = 'X'

  • IMPORTING

  • RETURN =

.

ENDIF.

*

Tags:
Not what you were looking for? View more on this topic or Ask a question