Update Sold to party address to Ship to party in parties involved

Dear Experts,
I have problem in Development, actually my requirement is while creating the service order user will give the Sold to party number. I want to update the ship to party address as per the given sold to party in the Parties involved.
Please guide.
Regards
Anandhan

Hi Anandhan,
Have you worked on call back event function modules earlier. Using a call back function module would be required more of coding and in your case its not necessary to use FM.
There is another simple way to achieve this requirement. You can create a custom implementation for the badi COM_PARTNER_BADI and use the method COM_PARTNER_MERGE.
This badi will trigger for all the partners maintained in service order, so we have pick only ship to party partner function.
1. Check the partner function field(partner_fct)  value in changing parameters CS_PARTNER_BADI, if it is your ship to party partner function then continue with below steps
2. Get the REF_GUID field from CS_PARTNER_BADI and
read the document process type and partner details.  Observe below sample code
lv_guid         = is_partner_control-document_id. "is_partner_wrk-guid.
     APPEND lv_guid TO li_guid.
     lw_object_name = 'ORDERADM_H'.
     APPEND lw_object_name TO li_object_name.
     lw_object_name = 'PARTNER'.
     APPEND lw_object_name TO li_object_name.
     CALL FUNCTION 'CRM_ORDER_READ_OW'
       EXPORTING
         it_header_guid       = li_guid
         it_requested_objects = li_object_name
       IMPORTING
         et_orderadm_h        = li_orderadm_h
          et_partner           = li_partner
       CHANGING
         cv_log_handle        = lv_log_handle
       EXCEPTIONS
         document_not_found   = 1
         error_occurred       = 2
         document_locked      = 3
         no_change_authority  = 4
         no_display_authority = 5
         no_change_allowed    = 6
         OTHERS               = 7.
     IF sy-subrc <> 0.
       RETURN.
     ENDIF.
3. Check the process type using li_orderadm_h table.
4. Read sold to party partner details from li_partner and pick the address fields and assign them to CS_PARTNER_BADI structure.
Best Regards,
Dharmakasi.

Similar Messages

  • How to update Sold to Party for a contract

    Hi Gurus,
    I got a strange and fuzzy requirement. My client wants to update the Sold-to-party in 2011 for the contracts created in 2010 with any status and with any sub-sequent documents to that particular contract. I know SAP wont support on this. because it is a standard functionality that we cannot update Sol-to-Party rather we can update BP,PY ans Shipto etc.... But still this my requirement. Anybody any solution is always helpful to me..
    Thanks,
    Bhargav.

    Hi all,
    I just want to add one more point to my requirement I am using this FM SD_SALESDOCUMENT_CHANGE to update Partners other than Sold-to-party. And I found out that we have another FM SD_PARTNER_SINGLE_MODIFY to update partners. this second FM is there in the first FM. So please provide your valuble solutions/comments
    Anticipating for your replies,
    Regards,
    Bhargav.

  • How to update Sold-To Party (In ORDER_SAVE BADI)

    Hi,
    I have a requirement as follows:
    In for a Sales Order, In ORDER_SAVE BADI, I have to do validation for Sold-to Party. If validation fails, I need to display an error message and I need to clear the Sold-to Party field, hence user has to select another sold-to party.
    Could you please let me know, how can I clear the sold-to party, in ORDER_SAVE BadI. Any FM's to do that?
    Thanks,
    Sandeep

    Hello Sandeep,
    why you want to delete the sold-to ? I think its just easier to give a error message in the log, so the users  could enter a new sold-to. Within the badi order_save you can prvent saving with exception do_not_save  - see note 1519171 for detailed information.
    Best regards
    Rene

  • Sold to party and Ship to party are the same but has different address

    Hi,
    I have problem here wherein Sales order has the same sold to party and ship to party but they have different address. When the customer master data is changed the sold to party in the sales order is also updated but the ship to party is not updated.
    I've checked the table VBPA and I noticed that the value of ship to party VBPA-ADRDA is 'E' (manually enetered).
    Is this the reason why the address of ship to party in sales order is not updated whenever the customer master is change?
    Another question, how does ship to party entered in sales order manually?
    Thanks in advance.

    Hi,
    Please correct me if I have understood the scenario incorrectly which I try to explain below:
    Sales order is created where SP and SH both have same address initially and while creating the SO, address of the SH was changed manually by Header>partners>SH
    Now master data for that customer is changed for address. As per the standard functionality of SAP, all sales order created for that customer will have new address for SP only.
    If address of SH needs to be changed in SO, it has to be done manually by the same way as explained in the above mails.
    As far as manually entering the SH in SO is concerned, system will automatcally selects the SH if only one record is available for SH. If you have specified more than one SH, system will give you an option to select one by displaying a pop up.
    Please let me know if you find this explanation suitable.
    Ravi

  • Delivery report output for'Ship-to party address and Sold-to party address'

    Hi Experts,
    We have an report output generated upon delivery creation.
    We need print following fields:
    Ship-to party #
    Ship-to party Name
    Ship-to Party Address
    Sold-to party #
    Sold-to party Name
    Sold-to Party Address
    As per i understand, we could get those field according to partner function....
    So experts, could please advise me from which table and field and logic to get above information....
    Thank you very much!!

    Hi,
    Are you changing partner details in delivery document?
    This partner address details will be updated in VBPA table.
    E.g change the partner street no.  in delivery document manually.
    Now goto VBPA table, enter correspondence sales document number for that delivery and execute.
    Click on partner function AG / WE get the address number (ADRNR) .
    Now goto ADRC table, enter this address number in ADRNR field and execute. you will get partner details.
    Regards,
    Chandra

  • Sold to party and ship to address is different

    Dear Experts,
    Sold to party and ship to party is different  address but when invoice is happened sold toparty adrees  displayed in ship to party
    how i can make the changes for ship to party kindly help me in this regards
    Thanks a
    Basavaraj

    Hi,
    This is what you needs to do.
    Create your Sold to Party "A" using the Account Group "Sold to Party" from Tx: XD01
    Then Create your Ship to Party "B" using the Account Group "Ship to Party" from Tx: XD01
    Then go to you Sold to Party using Tx: XD02
    Go to Sales area data / Partner tab
    Add your Ship to Party "B" there with Partner Function "Ship to Party"
    Save
    Now create a sales order from Sold to Party "A"
    Enter Sold to Party "A" and press enter
    You will get a pop up to select relevant Ship to Party for the Sales Order Header level with "A" or "B"
    Select relevant one at there.
    If you select "B" at the header, same will get copied to all line items later. Else you can select "A" and then change only the relevant line item partner to Ship to "B" at Item level as well.
    When you create delivery, relevant Ship to will be picked form the line item level.
    You can do same for Bill to Party and Payer as well.
    Best regards,
    Anupa

  • Excise invoice to ship-to-party but billing to Sold-to-party

    Hi Experts,
    My client wants to send pro-forma excise invoice to ship-to-party but wants billing to Sold to party. here Sold to party and Ship to party address will be different. can you tell me the settings which should I do.
    Thanks in advance.

    Hi,
    Create the Ship to party as a contact person and trigger the proforma excise invoice output type during proforma invoice creation.
    In the case of Normal Billing to Sold to party.
    regards,

  • Sold to party adress copy to ship to party

    HI,
    when customers place an order on the internet they get a choice to deliver to a different delivery address.
    When customers choose this option and type in a different address it does not ask them to enter in a tel number.
    Would it be possible in sap to copy the main tel number entered on the internet  into the ship to party tel number on all occasions?
    Internet orders have shipping condition E1
    Example delivery 807924096 which is an internet order, the sold to party tel number is 07923622906 the ship to party has a different address and no tel number, could the sold to party tel number be copied to ship to party tel number?how
    reagrds,
    Debesh

    Hi,
    You cannot do this directly. But using the user exits you can enable it.
    You can also save the telephone number provided by the user in some Z table and then take the values from the Z table and then enter them in the telephone number of the ship to party. May be this can also be scheduled as a job and can run twice a day, by which you can actually optimise the system performance.

  • Sold to party, Ship to party in VA05 report

    Dear Experts,
    I have one requirement in which I am supposed to display Ship to party and Ship to address fields along with sold to party field in VA05.
    1. Document Date
    2.Delivery Date
    3.GI Date
    4.PO Number
    5.Name
    6.Sales Doc Type
    7.Sales Document
    8.Created By
    9.Sold-to-party
    10.Name 1
    11.City
    12.Region
    13.Material
    14.Description
    15.Sales Unit
    16.Order Qty
    17.Confirm Qty
    18.Shipping Point
    19.Status
    20.Net Value
    21 Ship-to-party
    22 Ship-to-address
    Now the problem is I am not able to find appropriate user exit for the above requirement since Ship to party and Ship to address fields are not available in VBAP or VBAK tables and the existing user exits are
      PERFORM move_userfields USING 'VBAP'.
      PERFORM move_userfields USING 'VBAK'.
    Thanks in advance!!!
    Vishal
    Vishal

    Hi,
    For the sold to party and ship to party, get the values from VBPA-ADRNR where VBPA-KUNNR = VBAK-KUNNR and VBPA-PARVW = SP (Sold to party)
    For ship to party get VBPA-ADRNR  where VBPA-VBELN = VBAK-VBELN, VBPA-PARVW = SH.
    Once VBPA-ADRNR is known for sold to and ship to , pass them in ADRC-ADDRNUMBER and then get ADRC-NAME1, ADRC-NAME2, ADRC-CITY, ADRC-REGIO etc for printing the address details.
    Hope this helps

  • Sold-to-party not getting updated

    Hi
    we are trnasferring  outboud deliveries from system A to system B. in system a the delivery is with reference to order and when it comes to B we have custom delivery type which without order reference. we are using BAPI_OUTB_DELIVERY_CREATENOREF to transfer the delivery. all the data is updated correctly but the sold-to-party is not updated. In fact in the FM there is not import parameter for entering sold-to-party.
    In system B we tried to create a delivery without order reference using the same ship to party , in this case the sold-to-party is picked up by the system automatically. So when only replicating with the BAPI the sold-to-party is not picked up automatically. How do i update the sold-to-party. is there any FM to do this??
    thanks
    sankar

    Take a look at the OSS note 1069352 - it won't solve the issue but might explain something.
    Try using EXTENSION_OUT / EXTENSION_IN to add sold-to. Otherwise you might have to use something different. E.g. FM BAPI_DELIVERYPROCESSING_EXEC technically allows creating the deliveries in a scenario that you're describing:
    The preceding document can be in another system. To ensure that the entire requested quantity is generated in the delivering system and the corresponding requirements are planned in the planning system, for example, for cross-system deliveries SAP recommends creating unchecked deliveries (techn_control-check_mode = 'A').
    There are also IDocs for deliveries. Hope this helps...

  • Change log of document address for Ship to party in sales order

    hi experts,
    There is a case where Ship to party address is diffferent at sales order level and custome rmaster level.Can anyone help to find the  log of data inserted /updated in the customer address at sales document level. We tried CDHDR and CDPOS tables with object Adresse.But this is not giving correct information.

    Hi,
    In your case,I hope the Customer number is same at both levels.i.e. at Sales Order level and Customer master level but the address is different.
    Goto the T.Code "SE16".Enter the table Name as "KNA1".Enter the Custoemr Number and get the value from the field "Adress".
    Now Enter the table name as "VBPA".
    Enter the Address numebr you have noted from table "KNA1" and enter the select option as "Not Equla to".Pass the Ship-To-Party number under the field "Customer" and select the partner function as "WE/SH".
    Execute.
    You will receive all the list of sales orders where teh address is differed from master data.
    Regards,
    Krishna.

  • How to create ship to party and sold to party for DC10 during sales order ?

    Hello all:
    When creating sales order for a material in VA01 with sales Org 1000,
    distribution channel 10, division 00
    The system does not give me any Ship to Party and Sold to Party with the above combination
    How to create ship to party and sold to party with the above combination (Plant 1000,
    sales org 1000, distribution channel 10, during creation of a sales order
    Ironically, when creating material master for a material with a material type KMAT, plant 1000
    sales org 1000, the only distribution channel is populating in the input help (F4) is 10
    For which no ship to party neither sold to party is maintained in sales order creation
    Thanks in Advance!!

    Dear Eshwer
    It is bcoz, the said account groups (Sold To Party and Ship To Party) are not created in the sales area 1000 / 10 / 00.
    To create a customer master, you have to go to XD01, select the Account Group, Company Code and the respective Sales Area and execute.  In the Customer Master, you have three tabs, viz.General Data where you have give address details of the customer, then in Control Data, you have to assign the respective Recon Account and in Sales Area Data, you have to maintain the customer's sales related details.  Once you give all these datas and save the data, a customer code will be displayed at the bottom.
    Now go to VA01, input the sale order type and the sales area and execute.
    thanks
    G. Lakshmipathi

  • Configuring Ship to party,Sold to party and Payer

    Hi Experts ,
    Subject:- Ship to Party, Sold to Party and payer
    In the customized invoice the client requires the above mentioned addresses to be displayed.
    Because all these three Partners are Different.
    How to configure the same in sap. Only after configuring in sap the same will be reflected in the invoice
    Guide me in this regard.
    Thanks and Regards,
    Anand

    Hi,
    In General Only the Payer and the Ship to address will print on the invoice. As it is a client  requirement to print three addresses on the Invoice, first you should talk to ABAPER to  identity the window for the three  addresses
    Now you can get the Address from VBPA which is the partner table.
    Pick the Sales docment number which is VBELN  and then goto VBPA table and get the numbers for the customer (payer and ship to and sold to) with the input key as PARVW . The Address wil be different for each partner function,
    Then pick  the ADRNR number and goto ADRC table
    There u can find the fields in which the address will be stored and print on the printer  using smartform and program.
    regards,

  • 1 Sold to Party and N no. of Ship to Party "s?

    Heloo ,
    My Scenerio is like this follows - Please Provide me the solutions .
    Spencers Head Officer Order to me for 100 Quality of Articles and it directs 10 Branch (Outlets) to deliver .
    1.But now my Question is how to map 10 different Ship to parties in 1 Sales order and Customer Creation . But my BP & PY will be Spenscers Head Office.
    2. Say for example if i create 10 Branches (outlets ) in the Account Group of SH , How and where to Assign to Sold party ?
    Do the needful. Thank you.
    Regards,
    Amrita

    Hello,
    Create Spencers as the sold-to-party SP, then create 10 different ship-to-parties with the respective addresses, you may maintin all these in XD02 --> Give the sold-to-party number --> Sales area data tab --> Partners , by default the ship-to-party partner would have picked up with same number as the sold-to-party. Remove that and add all the 10 ship-to-parties with function SH.
    If you want to put this only in the sales order, you may do the same in Order--> Header --> Partners, here you may add all the ship-to-parties, this will be applicable to this sales cycle only.
    Prase

  • Sold to Party and Ship to Party Function module or BAPI

    Hi Experts,
       1) I need to create customer data,So i need to Function module or BAPI.
       2) Address create data Function module or BAPI.
       3) Sold to Party and Ship to Party Function module or BAPI relation ship.
    Thank you ,
    Dinesh Reddy
    Moderator message: anything else? please search for available information before asking.
    Edited by: Thomas Zloch on Oct 14, 2011 3:19 PM

    Hi,
      Try these Bapis
    BAPI_BUS2001_PARTNER_GETDETAIL Get Detail Data for Partner Data
    BAPI_BUS2001_PARTNER_GETLIST   Get Overview List for Partner Data
    Regards,
    Prashant

Maybe you are looking for

  • I-Tunes and and External Drive...Questions!

    Hello, starting my music collection seriously for the 1st time and have some questions. When you use an external drive how does i-Tunes recognize this? Will it still allow me to browse through everything ( album artwork etc) as if the music was in th

  • Regading for Support Package Stack

    Hi All, Can we apply ABAP patches from JSPM? I have downloaded ABAP support packages. I am waiting for yours reply. Thanks & Regards, Charanjit.

  • A 'normal' thumbnail-image structure with Spry

    Hello. I would like to ask the devolopers of Spry if it is possible to implement, with Spry classes, a basic structure for the opening of an image from a thumbnail. I examined your examples about the photo gallery but I would like to perform a more s

  • Email Tracking Older Data

      Hi All, Hope u'll all be doing well, We are using in-premises Exchange 2010. I have come across a different task today in the morning, My GM asked me that 3 months ago he instructed Mr. X to send an email to Mr. Y (Mr. Y is External email), did he

  • ECC: Unknown named curve: 1.3.36.3.3.2.8.1.1.7 (brainpoolP256r1)

    Hello, I've stumbled on a problem with the ECC and I would like to know if anybody did so too and what can be done. In our application we need to check X509 certificates. Therefor we parse them with the java.security.cert.CertificateFactory like this