Updating partner function when creating customer XD01/XD02

Hello all, I have the following requirement to do:
When creating a customer for a certain account group in XD01/XD02, I need to update the partner functions associated to this customer.
I have tried, the ENHACEMENT  SAPMF02D with function EXIT_SAPMF02D_001, but when changing table content T_KNVP, this content is not taken into account and the values are not stored in DB.
I have tried too BADI's CUSTOMER_ADD_DATA and CUSTOMER_ADD_DATA_CS, but the content of T_KNVP in CUSTOMER_ADD_DATA cannot be changed.
I would like to avoid BTE's for now.
Can someone give me a hand on this?
Thanks in advance!

Solution: BAPI CUSTOMER_UPDATE

Similar Messages

  • Update partner function before saving Customer (XD01/XD02)

    Hello Experts,
           I need to update my partner function table in Sales Area Data of Customer Master (XD01/XD02)
    before saving the customer. Is there any exit where I can do that.
           I tried using Enhancement SAPMF02D. Exit - EXIT_SAPMF02D_001. Where I modified the table T_KNVP. But, it again defaults to its original value.
    Any help is appreaciated.
    Regards,
    DNP

    I rephrase the question -
    I can do an update after a Customer is created but is it possible to trigger a program everytime after a Customer(XD01/XD02) is being created.
    Regards,
    DNP

  • How to update partner functions in customer master

    Hi all,
    I want to update the partner functions for the customer master using transaction code XD02. I created the LSMW by means of recording but it doesn't work because the partner functions for the customer changes.
    for example , certain customers have shipto paty, sold to party , bill to party payer and forwarding agent. some customers wont have all the above mentioned category.they may have only ship to party, sold to paty & bill to party.
    Is there any other alternative way to update the partner functions for the customer. 
    Regards,
    A.Rathinaprakash

    Hi A.Rathinaprakash,
    Please use the FM 'SD_CUSTOMER_MAINTAIN_ALL' to maintain the partner functions in the customer.
    Pass the partner details in the TABLES parameter T_XKNVP.
    Regards
    Chetan

  • Set default value on field KNA1-AUFSD when creating Customer

    Hi,
    How to set default value on field KNA1-AUFSD when creating customer master using XD01/VD01?
    I have tried user exit SAPMF02D, but all KNA1 values are read only.
    Thx

    Hi
    Try to implement an enhancement option in include MF02DFEX. (at the beginning before call to FM CALL CUSTOMER-FUNCTION '001'.).
    and Initialize the value for KNA1-AUFSD.
    In this Include you can see that there is a call for CALL CUSTOMER-FUNCTION '001'.
    So even you test/check the initialized value for field KNA1-AUFSD is updated by putting a break point in this function module after implementation of your enhancement SAPMF02D.
    Regards,
    Dwaraka.S

  • Update partner function in KNVP table using FM sd_customer-maintain_all

    Hi All,
    I have to update Partner Function ‘PARVW’  in KNVP table using FM sd_customer_maintain_all.
    I had already created a BDC program for updating which is running successfully.
    But  my requirement is to create a BAPI using FM customermaintain_all.
    Ex:  Tcode VD02
              KUNNR          PARVW             KUNN2
    Old data      123          Z1          70006666
              123          Z2          70007777
    Req. output      123          Z1          70006666
              123          Z1          70007777
    PARVW ‘Z2’  should not exist after updation.
    When updating, I am getting the error message to my inbox as
    “ Error Info...   F2 802: System error in table KNVP ”
    The above error is triggered while committing work after execution of  ‘SD_CUSTOMER_MAINTAIN_ALL’.
    The options I tried while looping at internal table containing kunnr, parvw & kunn2
    CALL FUNCTION 'SD_CUSTOMER_MAINTAIN_ALL'
    EXPORTING
        I_KNA1                              = w_kna1
      I_KNB1                              =
        I_KNVV                              = w_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                             =
      T_XKNVL                             =
        T_XKNVP                             = I_XKNVP
      T_XKNZA                             =
      T_YKNAS                             =
      T_YKNBK                             =
      T_YKNB5                             =
      T_YKNEX                             =
      T_YKNVA                             =
      T_YKNVD                             =
      T_YKNVI                             =
      T_YKNVK                             =
      T_YKNVL                             =
        T_YKNVP                             = i_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 eq ‘0’.
    Commit work and wait.
    Endif.
    All above tables have a field called ‘KZ’ which has options
    U-update
    D-delete
    I-insert
    E-………(I don’t know)
    Ex: T_XKNVP structure = KNVP Structure + Field ‘KZ’.
    Documentation for this FM is not Available in English or German
    1.  I tried sending Z2  KZ as ‘D’ first &  Z1 with KZ as ‘I’ with business partner of Z2 (KUNN2)
         as single update.
    Ex: T_XKNP table
    KUNNR          PARVW             KUNN2          KZ
    123          Z2          70007777     D
    123          Z1          70007777     I
    2.  I tried it as a separate delete record and insert record i.e calling the FM twice .
    3.  I tried passing table  T_YKNVP with old partner data + TXKNVP table new partner data
    Ex: T_YKNP table
    KUNNR          PARVW             KUNN2          KZ
    123          Z2          70007777     U or space (I tried both one after another)
    4. All combinations for field ‘KZ’  are tried.
    Please help me to overcome this problem.
    I )   I need which parameters are to be passed to FM for updating partner function in KNVP table .
    II)   Do I need to pass structure I_KNA1 or I_KNVV to FM ? (Blank or with values corresponding to   
         partner function ).
    III)  Any sample code which can guide me.
    Even a small hint or clue from you will certainly help me.
    Thanks in Advance.
    AJAX

    i have the same problem. I need to update the partner function PARVW thru a program that i created. I tried to use this FM but it didn't work. Anyone knows another FM that i can use to update the KNVP table?

  • Update partner function using DEBMAS06

    Hi
    I am using DEBMAS06 to add partner to partner function of  a customer. As I need to update only the partners i am passing partner no and partner function to e1knvpm segment.
    But the Idoc actually tries to delete the existing partners of the customer.
    I just want to add a new partner.

    no1 answered

  • Function module to give all partner functions for given customer

    Can anyone tell me function module name which gives all partner functions for a customer. For ex if we give customer number and sales area then it should give the list of all partner functions of this customer.
    I know 'CUSTOMER_PARTNERFS_GET' function module. But I want other than this.

    Hi,
    U can join VBAK and VBPA table and get the parrtners of the customer..
    Regards,
    Nagaraj

  • How to update partner function in PO.

    Hi guys,
      Please help me, How to update partner function in PO.(Transaction ME23N),BAPI_PO_CHANGE is not updating this.it gives error like partner roles not change.

    DATA :  li_return         TYPE TABLE OF bapiret2 WITH HEADER LINE,
                 li_popartner    TYPE TABLE OF bapiekkop WITH HEADER LINE,
                 lv_error           TYPE  FLAG  .
    li_popartner-partnerdesc = X1.
      li_popartner-langu       = sy-langu.
      li_popartner-buspartno   = 'vendor1'.
      APPEND li_popartner.
      CALL FUNCTION 'BAPI_PO_CHANGE'
        EXPORTING
          purchaseorder = ebeln
        TABLES
          return        = li_return
          popartner     = li_popartner.
      LOOP AT li_return.
        WRITE / li_return-message.
    Check error
        IF li_return-type = lc_E OR li_return-type = lc_A.
          lv_error = 'X'.
        ENDIF.
      ENDLOOP.
      IF lv_error IS INITIAL.
        CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
      ENDIF.
    Is there any config issues are there And also I am going to pass any values .
    HI,
      How to update the confirmation tab in PO item level.
    I write this code tell me i am going to pass any values or not.
    DATA:
        li_ekes               TYPE STANDARD TABLE OF uekes .
      CALL FUNCTION 'ME_CONFIRMATION_UPDATE'
                          EXPORTING
                            I_EBELN = lwa_z1confirmations-ebeln
                          TABLES
                            XEKES   = li_ekes.
                        IF sy-subrc EQ 0.
                        ENDIF.

  • Help!!! - When Creating Customer  I get this ERROR "Provide a positive integer for minimum customer balance amount or percent when balance amount overdue type is amount or percent respectively."

    When Creating Customer  I get this ERROR "Provide a positive integer for minimum customer balance amount or percent when balance amount overdue type is amount or percent respectively."
    I tried troubleshooting when I saw the another post and created with a new customer profile class, but still getting an error, though I created another profile like below and attached this to another existing customer it worked, but when I tried creating a new customer it is still giving me the error. I am Using Oracle Applications R12.1.1
    Steps I followed in Creating a New customer Profile
    ==== Make sure the new Customer Profile class which you will create is in active state. Cross check below steps while defining a customer Profile class.. e.g. Name : DEFAULT (and it's active)
    *1) Profile Class Tab :*
    a) Balance FWD Billing : Not enabled
    b) Invoicing --> Tax Printing ( Summarize By Tax Name), Grouping Rule (DEFAULT)
    c) Set Terms as per ur requirement , do allow discount & Override terms
    d) Set Dunning as per your requirement,
    e) Filled in Collectors info as per your requirement with Credit Check enabled...
    f) Receipt --> Auto cash Rule set as 'Standard'..
    *2) Late Charge Profile* Set it as per requirement
    *3) Profile Class Amounts* e.g Say Currency set as "USD"
    a) Credit Limit : 100000
    b) Order Credit Limit : 100000
    c) Minimum Receipt Amount : 1.00
    d) Min statement amount : 1.00
    e) don't put any value in Exchange Rate type (e.g, monthly, Plan etc..)
    f) Minimum Customer Balance : Amount ------> Value: 5.00
    g) Minimum Invoice Balance : Amount ------> Value: 5.00
    h) Minimum Charge per invoice : 1, Maximum Charge per Invoice : 100 Under Interest Charge
    i) mention Type as Fixed Rate, Value : 10
    j) You can avoid setting the Penalty Charge for the time being..
    Step-2_ a) Open a customer ..*go to Bill to site details* --> Click on Profile Tab --> Under Profile Class field please include new profile class which is created by you (e.g DEFAULT) . b) Go to Profile Amounts Tab --> Click(Show) on Currency USD --> Verify the set up here as well   I could see this.
    When I tried creating an new Customer using the new profile, it's repeating the same error. Please help.

    Hi
    You get this error when profile class amounts are not set for all the currency.  Go back to your profile and ensure that the profile amounts are set for all the currencies found, whether you are using it or not.
    Regards

  • Problem Updating  partner details when the confirmation is created.

    I want to update the partner details when the confirmation is created
    In SRM (non -sus ), Confirmation is created using the function module : bbp_pd_conf_create .
    While creating confirmation, only item wise confirmation details are updated.
    But the partner details of that confirmation is not updated.
    bbp_pd_po_Getdetail is used to get the purchaser order details .
    the same partner details are used in the confirmation create function module .
    the following are the fm  used for the above purpose ,
    BBP_pd_conf_create
    bbp_pd_conf_update
    bbp_pd_conf_save
    What are the details i should change in partner details to get updated. like guid information..
    Please provide some suggestions ...
    Thanks,
    Uma

    In BBP_PD messages
    i can see the header , item  and Stats details .
    What ever value i retreive from PO getdetail fm , i pass it to the partner details while creating confirmation. only item details get updated but not partner details ,
    I think its missing with  the p_guid details. i dont know how to pass value consistently the p_guid value in hte partner when the item details are confirmed.

  • Give "Number of an SD business partner" internally while creating customer

    When we create a new custpmer by VD01 or XD01, at the "partner functions" tab, the number for each partner role is given internally. Where is the customization for the internal or external partner number? I want the system to give the partner number internally for the new customer's partner roles but it is externally customized. The partner numbers (which can be seen in "Partner Functions tab") for the new customer being created should be the new customer's own number and should be given internally.
    Thanks in advance.

    Hi
    To assign the internal or external no. range to Customer is based upon the account Group. It can be assigned in IMG, the path is ;- IMG>Financial Accounting>Account receivable account payable.> Customer Account> Master data>Preparation of creating Customer Master data>Assign No. range to customer Account group.
    Regards
    Amitesh

  • Partner functions for SAP Customer Master

    I am in the MDM solution definition phase for SAP Customer Master at one of our Cients place. The requirement is to set up a central master data scenario where creation & modification of any customer record will be done via MDM. The following components of Netweaver are in the landscape - SAP MDM, EP, XI.
    I need clarification on the following points -
    -  Is it possible to set up the partner function in MDM, if so, how?
    -  Need to replicate the standard SAP functionality where the system can be configured to create Ship To, Payer, Bill To automatically when a Sold To record is created. Is this possible? Are there any work arounds?
    Regards
    Arvind

    Hi,
    Hi Arvind,
    -  Is it possible to set up the partner function in MDM, if so, how?
    Partner Function comes under Condition Technique in SAP ECC.here some config has to be done.
    For mapping it in MDM, First create a Qualified Table - Partner Function.Determine the Non-Qualifiers and Qualifiers.Then as said by Suresh, u need Java API stuff to complete this task and frontend being EP.
    - Need to replicate the standard SAP functionality where the system can be configured to create Ship To, Payer, Bill To automatically when a Sold To record is created. Is this possible? Are there any work arounds?
    It can be done using EP as front end and Java API to dertermine the partner based on the account group.
    Thanks,
    Felix
    Edited by: Felix on May 9, 2008 1:38 PM

  • How to update partner function in ME_PROCESS_PO_CUST

    Hi,
    does anyone know how to update the partner function in PO? transaction ME22N or ME21N.
    I have checked the BADI ME_PROCESS_PO_CUST and there is no way for me to set the partner.. there is a method get_partners but i didn't find a way to set it..
    I cannot just modify the table EKPA since when creating PO, there is no PO number yet.
    Can anyone help? Please.
    Thanks

    Hi Esaki,
    1) Define new field selection in configuration "Define screen layout at Document level"
    2) write code in fieldselection_item_refkeys as follow
    get item data
    if your condition
      ch_key0 = new field selection
    endif
    Hope it can help u.
    Grace

  • LSMW, CREMAS04, and updating Partner Functions

    I am involved with converting legacy data into SAP. To populate the SAP Vendor Master correctly will involve 3 passes using LSMW:
    Pass #1: use IDOC CREMAS04 and populate the majority of master record fields
    Pass #2: use BAPI: Business Object "BUS4001"; Method "SAVEREPLICA"; Message Type "ADRMAS"; Basic Type "ADRMAS03" to update Vendor record address data.
    Pass #3: use IDOC CREMAS04 and update Head Office, Alternate Payee, and related Partner Function data.
    The problem I am having is best explained using the following example:
    When a vendor record (ex: Vendor Number 300004) is first created, the following 3 Partner Functions are also created automatically to reference the same vendor number: OA, VN, & PI (Ordering Address, Vendor, & Invoicing Party):
    OA    Ordering Address    300004   Vendor A
    VN    Vendor                   300004   Vendor A
    PI      Invoicing Party        300004   Vendor A
    This particular vendor is actually one of many "plants" or "warehouses" of a larger vendor, and I need to configure the record to reflect that the Purchase Orders go to the Parent Vendor (Head office) and that the Invoice comes from the same source. Therefore, I need to remove or edit the existing OA and PI partner functions so that I only end up with the same 3 Partner Functions, but the linked vendor record for partner functions OA and PI needs to be that of Head Office.
    Example: if using Vendor Number 300005 "Head Office Vendor"
    OA    Ordering Address    300005   Vendor A
    VN    Vendor                   300004   Vendor A
    PI      Invoicing Party        300005   Vendor A
    What I am actually seeing when I post the IDOC is the following:
    OA    Ordering Address    300004   Vendor A
    OA    Ordering Address    300005   Vendor A
    VN    Vendor                   300004   Vendor A
    PI      Invoicing Party        300004   Vendor A
    PI      Invoicing Party        300005   Vendor A
    Can anyone shed some light on this?

    Don,
    I am trying to work with the same data that you discussed in this thread.  Can you send me some additional details on your Pass #2?  I was successful in Pass #1, particularly in adding new PI vendors when necessary and deleting the existing internally created PI vendors.  But I'm stuck on Pass #2 where I want to add the extended address information that you mention using the SAVEREPLICA BAPI.  I can certainly use the recording method, but would like to leverage the power of the BAPI approach.
    Thanks in advance!
    Wes

  • Regarding sample code to update partner function using SD_PARTNER_UPDATE

    Hi All,
    Please provide some sample code to update/add partner function using FM 'SD_PARTNER_UPDATE'.
    regards
    Vishnu

    A better option would be to use a break point on this FM while creating a sales order. That way you will know how standard uses this FM.
    Thanks,
    Vikram.M

Maybe you are looking for

  • MDMP unicode conversion - Vocabulary maintenace

    Hello,           W have upgraded 4.5B MDMP system to ECC4 EHP4 and now we are in process of unicode conversion. please advice on as specified below. In SPUMG Scan process, we have completed the following scans: a) Tables without language Info b) Tabl

  • Customer order number in CO-PA

    Hello! Does somebody know where I can see the rule for the derivation of the customer order number in CO-PA? As it is a standard characteristic I can not see the rule in transaction KEDR. Our problem is... we use the typical third-party order process

  • Anyone successfully using WL 6.0 and oracle.jdbc.xa.client.OracleXADataSource?

    My final goal is to have two xa pools pointing to different db's and have them in the same user transaction and do a 2 phase commit. I can't get past connecting to a single xa datasource. I have "Grant Select on DBA_PENDING_TRANSACTIONS to public". M

  • Is there a solution to the duplicating calendar and contact entries

    has anyone found a solution to this problem of duplicate calendar and contact entires for DM for mac? its driving me crazy and makes the program unusable thanks! www.whatsgoodblog.com What's Good is your one stop site reviews about everything. http:/

  • I cant send the pic msg in sms !

    Can anyone help me, how to send a normal black and white pic msg from 5800 ?