No Partner details in new order : CRM_ORDER_MAINTAIN

Hi .....
I am trying to create new order in which i am getting error related to partner data though i am passing al the data into the CRM_ORDER_MAINTAIN function.
I am not able to figure out what is the problem.
Following is my code part ->
READ TABLE lt_src_partner_or INTO ls_src_partner_or
        WITH KEY ref_guid    = lv_guid_h
                 partner_fct = '00000004'.
    if sy-subrc eq 0.
    wa_partner-ref_guid           = lv_guid_h."gs_sel_cont-guid_b.
    wa_partner-ref_handle         ='0000000000'.
    wa_partner-ref_kind           = ls_src_partner_or-ref_kind. "'A' .
    wa_partner-ref_partner_handle = ls_src_partner_or-ref_partner_handle."'0000'.
    wa_partner-ref_partner_fct    = ls_src_partner_or-ref_partner_fct. "'00000003' .
    wa_partner-ref_partner_no     = ls_src_partner_or-ref_partner_no.  "100040  " THIS IS THE OLD value
    wa_partner-ref_no_type        = ls_src_partner_or-ref_no_type.
    wa_partner-ref_display_type   = ls_src_partner_or-ref_display_type.
    wa_partner-partner_guid       = ls_src_partner_or-partner_guid .
    wa_partner-kind_of_entry      = ls_src_partner_or-kind_of_entry. "  'C'
    wa_partner-partner_fct        = ls_src_partner_or-partner_fct. "   00000003 "new value
    wa_partner-partner_no         = ls_src_partner_or-partner_no."'92921'p_tbill. "     0000100007 " THIS IS THE NEW VALUE
    wa_partner-display_type       = ls_src_partner_or-display_type. "    BP
    wa_partner-no_type            = ls_src_partner_or-no_type . "  BP
    wa_partner-mainpartner        = ls_src_partner_or-mainpartner. "  'X'
    wa_partner-relation_partner   = ls_src_partner_or-relation_partner. "    '00000000000000000000000000000000'
    wa_partner-addr_nr            = ls_src_partner_or-addr_nr . "   '0000010673'
    wa_partner-addr_np            = ls_src_partner_or-addr_np . "  ''
    wa_partner-addr_type          = ls_src_partner_or-addr_type."   '1'.
append ls_tb_partner_om to lt_tb_partner_om.
    INSERT wa_partner INTO TABLE it_partner.
    endif.
    clear : wa_partner, ls_src_partner_or.
   * populate field_names
    REFRESH lt_field_names.
    ls_field_names-fieldname = 'DISPLAY_TYPE'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names ."lt_field_names.
    ls_field_names-fieldname = 'KIND_OF_ENTRY'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names ."lt_field_names.
    ls_field_names-fieldname = 'NO_TYPE'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names."lt_field_names.
    ls_field_names-fieldname = 'PARTNER_NO'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names."lt_field_names.
ls_field_names-fieldname = 'PARTNER_FCT'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names."lt_field_names.
     ls_field_names-fieldname = 'REF_PARTNER_NO'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names."lt_field_names.
    ls_field_names-fieldname = 'REF_PARTNER_FCT'.
append  ls_FIELD_NAMES to lt_FIELD_NAMES.
    INSERT ls_field_names INTO TABLE lt_field_names."lt_field_names.
build input fields
    ls_input_fields-ref_handle = '0000000000'.
    ls_input_fields-ref_guid =   lv_guid_h . "4733030909B64D4D92A959BA5334B6F8.
    ls_input_fields-ref_kind =   'A' .
    ls_input_fields-objectname = 'PARTNER' .
    old partner number needs to be passed here
     CONCATENATE  '000000000014' ls_src_partner_or-ref_partner_no '          BPBP' INTO ls_input_fields-logical_key. "=. "000000000003100040          BPBP
    ls_input_fields-field_names = lt_field_names."lt_field_names.
    INSERT ls_input_fields INTO TABLE ct_input_fields.
     CONCATENATE  '000000000002' ls_src_partner_or-ref_partner_no '          BPBP' INTO ls_input_fields-logical_key. "=. "000000000003100040          BPBP
    ls_input_fields-field_names = lt_field_names."lt_field_names.
Set the first line for 000000000003
append ls_INPUT_FIELDS to lt_INPUT_FIELDS.
    INSERT ls_input_fields INTO TABLE ct_input_fields."lt_input_fields.
    CONCATENATE  '000000000003' ls_src_partner_or-ref_partner_no '          BPBP' INTO ls_input_fields-logical_key. "=. "000000000003100040          BPBP
    ls_input_fields-field_names = lt_field_names."lt_field_names.
Set the first line for 000000000003
append ls_INPUT_FIELDS to lt_INPUT_FIELDS.
    INSERT ls_input_fields INTO TABLE ct_input_fields."lt_input_fields.
set the second line for 000000000004 - the only difference is the logical_key
    CONCATENATE  '000000000004' ls_src_partner_or-ref_partner_no '          BPBP' INTO ls_input_fields-logical_key. "=. "000000000004100040          BPBP
    ls_input_fields-field_names = lt_field_names.
    INSERT ls_input_fields INTO TABLE ct_input_fields.
Please tell me where i am wrong ???
Do i need to include some more fields in input parameters of crm_order_maintain function ?
please help me experts .
Thanks and regards
Edited by: Shoaibmemon on Jun 27, 2011 2:42 PM

Hi,
    U need to execute a BAPI for customer master change. This needs to be checked whether we can call the BAPI through the exit u mentioned or even on Save.
Regards,
Deepak

Similar Messages

  • Changing the Ship-to partner details in Sales order header through exit

    Hi all,
      I have a requirement where in during the process of the sales order creation, based on certain
      criteria, the details in the ship-to partner would have to be modified.
      These details like the Name, Street, etc would be maintained in a local table and based on the criteria,
      the appropriate record from this table would be fetched and updated to the ship-to partner.
      I was trying to implement this in the MV45AFZZ user exit. However, I was not able to update this through the exit.
      Would I have to somehow update the ADRC table directly through this exit or is there any better method.
      Please suggest.
    Regards,
    Sudeep

    Hi,
    If you could not find Street in this Routine call the BAPI BAPI_BUPA_ADDRESS_CHANGE to update Street and required details ..
    Thanks and regards,
    Sree.

  • FM for updating Partner details in Sales order

    Hi,
    Pleaes let me know the FM to update partner functions in sales documents. FM is expected to only update partners and shouldnu2019t update pricing or incompletion or anything else. thanks

    Look at function group V09A - Partner processing SD. Also investigate module SD_PARTNER_UPDATE.

  • How to include a new Z Partner Function in Sales order header drop down lis

    Hello SAP experts,
    We have come up with a new requirement to include a custom Partner Function-ZI  in dropdown of SO header-Partners field.
    Current scenario- Presently we are maintaining this partner function  ( Say ZI-  Institute ) in customer master data-Sales area tab.There could be more than one partners under this PF in master data. While entering sales Order, all partners associated are displayed in Header- partners tab, where only SP, SH, BP, PY partner functions are displayed.
    Requirement- 1. Is to  provide Drop down of this ZI-Institute partner function (which I did not find presently) in SO header-partners field and user should be able to provide one of partner function as available in Customer master ( as there are more than one partners that can be set in Customer master data but user need to be able to provide ONE of this ZI partner fucntion in DROPDOWN of PF tab in SO header ).
    2. In addition, How can I link this new partner function in related sales reports against that particulat order and invoice?
    Kindly suggest your valuable inputs as what should be the procedure to get this.
    Many thanks in advance.

    Hi,
    Go to partner determination by VOPA
    OR
    IMG >> SD >> Basic function >> Set up partner functions >> set up partner function for sales document header
    click on partner function and Maintain partner function ZI  and back
    Then select your existing partner determination procedure (Standard is TA) and click on PARTNER FUNCTIONS IN PROCEDURE and add partner function. and make it mandatory so even user forget to mention then at the time of saving system can remind user 
    Then double click on PARTNER DETERMINATION PROCEDURE ASSIGNMENT
    Assign partner procedure to sales document
    Now when you creating sales order go to header partner tab and enter you institute partner number
    For sales order and invoice report
    Execute this report by selecting partner function ZI in VA05N and VF05 respectively
    kapil

  • Adding Forwarding Agent to Partner details in a Sales Order.

    Hi Experts,
      Below is the detailed scenario :
      We have inbound orders been created by Idocs Orders04 using the Idoc_Input_orders function module.
    the requirement is that if the partner forwarding agent is not been populated in Idoc then we need to add the same in the SO Partner details from Z table based on the sold to party in the idoc.
    Can anyone please help how I can proceed with the requirement. I have created a Z table and maintain the entries. I am not understanding where i should be doing the Coding for the same.
    Thanks and Regards,
    Nimisha.

    Hello,
    inside the VA01-transaction there are the userexits EXIT_SAPLV09A_001 to  EXIT_SAPLV09A_004 influencing the partner determination. Think most probably you could use the EXIT_SAPLV09A_004
    (Enhancement is V09A0004).
    You could switch on that one and look, which partners are in the order at that point of time.
    Regards
    Wolfgang

  • Not able to update the partner with a new partner during change order ?

    Hi Experts,
    I want to update a partner which is present in a sales order with a new partner. When i create a new order, i ll give partner function ship-to-party and partner no 1 for this partner function. And from a fucntion module, i want to change this partner no 1 to partner no 2 but when i try to pass the required values to crm_order_maitain, it is adding a new line in partner tab as same partner function and partner no 2 but my requirement is to update from 1 to 2. How to do this??
    Please help me in this regard.
    Thanks a lot in advance!!
    Regards,
    Lakshman.

    Hi,
    I have similar requirement to redetermin all the partner functions when the sold to pary is replaced with another one while creating complaint.
    Can you share how you managed to solve yours.
    Thanks
    Kumar

  • Partner details are not getting captured to the purchase order from the ven

    Hi,
    Issue : ( ECC PO)
    Partner details are not getting captured to the purchase order from the vendor master.
    We found that the partners are not getting captured in ECC PO's automatically from the vendor master. We checked for all the config and everything seems to be o.k, but could not figure it out.
    Any suggestions are highly appreciated.
    Regards
    Sudhakar

    Hey Sudhakar,
    I believe what is happening here is that the ECC PO document type has not been assigned to the partner determination procedure.
    If this is working properly for standard POs, then,
    Go to Partner detrmination under Purchasing>  Partner Settings in Purchasing Documents> Assign Partner Schemas to Document Types.
    and enter teh appropriate document type and refer it to the procedure you have for NB Pos

  • Block change of Partner details in order

    Dear all,
    When we go to the Headers-->Partners tab in a sales order in the change mode, and double-click on the Partner mention there, a window opens wherein we can change the partner address and region. And thus make it different from that maintained in the CMR. This change gets reflected in the sales order.
    Bur when we do billing of this order, the original address and region from the CMR gets copied.
    Is there any means by which we can prevent this change of partner details while in the sales order?
    Or if not possible, then how can we maintain the consistency of data in the billing doc.?
    Plz guide.
    regards
    SAPshed

    Hi,
    Screen variants
    Screen variants allow you to simplify screen editing by:
    Inserting default values in fields
    Hiding and changing the ready for input status of fields
    Hiding and changing the attributes of table control columns
    A screen variant contains field values and attributes for exactly one screen. A screen variant can, howevever, be assigned to multiple transaction variants. Screen variants are always cross-client; they may, however, be assigned to a client-specific transaction. They can also be called at runtime by a program. The different possibilities for calling screen variants guarantee great flexibility of use.
    For more information, see: Calling Screen Variants
    A specific namespace has been designated for screen variants and they are automatically attached to the Change and Transport System.
    For more info goto SHD0 and click 'i' button(information.Info is given very well.
    Regards,
    Amrish Purohit

  • How to get Sales Order Partner Details at Item Level

    Hi,
    Is there any FM/BAPI to get the Order Partner Details at Item Level, using the Sales Order Number ?
    Thanks

    VBPA is the best table.
    You can query that table
    But you should be carefull about item number:
    in POSNR, if you observe the entries, you will find one entry with '000000': This corresponds to header record and the rest is at item level.
    Thanks
    Kiran

  • Open details in new window

    Hi all,
    I have created a navigation button in my calendar in order to see business partner details for an activity.
    Everything works fine now but when I click on a business partner to see its details the account summary page replaces my calendar page. If I press the "Back" button, I go back to Calendar but the activity is not selected any more (I have to click on it again). That's why I am trying to display account details in a new window.
    And my question is: how can I tell PC-UI that I want to open a new window?
    Thank you.

    You can freeze individual windows by clicking on the push pin at the top left. The next object will open in a new window.
    You can make this the default behavior by selecting 'Automatically Freeze Object Viewer Windows in Tools -> Options -> Database -> Object View Parameters

  • Re: Who can I complain to about a new order being ...

    Ordered on 5/05/2015, online, via a Quidco referral. £160 cashback, £50 SB voucher promised.
    Delivery of equipment date missed.
    Phoned BT, told "order being processed, don't worry"
    Original connection date? 15/05/2015
    Requested to keep the existing landline number. Told this was okay, would be switched 24 hours after BB activation.
    16/05/2015 - no connection. no hub. Called BT, still no equipment. There was a problem, because fibre was already active, with previous account holder.
    15/05/2015 connection date changed to a new date of 26/05/2015.
    Had to do a completely new order over the phone. New problems now because NOT ONLINE ORDER want us to pay more.....
    We received the "delivery" we were waiting home for - a box that was designed to fit through the letterbox....landed on the doormat. No need to wait home....
    Existing BB connection cut off on 26/05/2015
    Broadband was supposed to be reconnected on 27/05/15.
    An engineer called on his mobile to gain access. We had not been told one was attending/required. We were not at home either.
    The job was eventually rebooked for 1/06/15. The engineer arrived at 8.25am, was there for 5 minutes, left for about 25 minutes (cup of tea i dare say) and then returned, and everything was working. Well, everything but the TV.
    The same issues as the OP, paid 1 years line rental up front, via a credit card, paid £36.95 connection and delivery for the fibre/hub. No payments were taken, fortunately. TV package was ordered at the same time too. Its 04/06 now, still no TV.
    Still waiting 9 days after original BB install date, no TV equipment. (It's supposed to be here tomorrow, the 5th June, fingers crossed) 1 month after order (not bad by others stories, but still 3 weeks later than original date.)
    There have been additional issues. Lengthy phone calls as the order is now "a telephone order", not an "online order" - so we are troubled about losing the £160 Quidco cashback.....and the £50 SB voucher. We have been assured by two people on the phone that we will receive these amounts.....but we have also been lied to as many times too.
    Received email detailing "Activation fee Infinity 1 option 1 £30, Activation fee infity 1 £30, total to pay £60
    Phoned BT, told this was an error they said they would remove it from the bill
    Received a bill today, DOUBLE activation charge for same product STILL ON THE BILL.
    Wanted to pay 12 MONTHS line rental up front, TOLD BT REPEATEDLY. But you won't sort it out for us.
    Why should I pay the first months line rental and then another 12 months up front when you get around to sorting it out, effectively tying myself into a 13 month contract? I may want to leave, after all, everything goes up in price when the 12 months discounts end......
    Renumbering? 3 or 4 phone calls to BT. Still not done. 30 second phone call today says it will be done "tomorrow, but after midnight" Thats the days AFTER tomorrow then?
    The whole process has been nothing but stress. It took over half an hour on the phone just two days ago, to sort out the mess with the missing TV package.
    Ordered the TV package online as part of the "QUIDCO" deal. No activation fee mentioned. Order confirmation received - no activation for TV package mentioned.
    Latest call to sort TV package, tells me £35.00 activation fee. The guy had no idea what we had already "ordered" - it looks as though you don't actually keep records of what people order at all??
    Original TV package confirmed as "BT Sport Albertz" package. He apparently after working at BT for 20 years, had never heard of this TV package. He denied its existence. Its on my email.
    I only wanted the Netflix (£6.99, two screens) and no additional TV channels. Online, the activation is currently showing £19.00 I cannot remember seeing one, and it hasn't been mentioned. Who knows if it wasn't on special offer the day I ordered? Your offers change constantly. He says he has to put £35, but ask for it to be changed to £19 because it was originally online order. We have not received confirmation of these prices yet.
    So to summarise. Pathetic customer service. Failed communication. Lies. Lack of decent record keeping. Pricing changing. Overcharging.
    £30 too much STILL on first bill.
    £35 instead of £19 for activation of TV, not yet received or confirmed.
    Lost discount because you REFUSED TO SORT OUT LINE RENTAL SAVER. (£33.98 loss)
    If I pay this now, on month 2, I am forced into 13 month contract with yourselves resulting in further losses due to increased costs)
    Potential loss of a)£160 Quidco referall due to fractured ordering. b)Sainsbury Voucher of £50 because offer has changed since original order date.
    Amount of stress - £ priceless.
    Yet to see if TV package arrives and is connected. But because TV package is now running a week behind the contract dates of the broadband, this will mean that if I cancel the BB after 12 months, I will not be able to use the TV package, as it WONT WORK. So, BT have you ensured I suffer further losses?  The phone line was switched over on the 25th May, BB on the 1st June and now TV should be 5th June.  If it arrives/works.  So who is paying for my 13 days over contract that is being enforced by yourselves, since I will be forced to keep the phone to keep the BB (at £10.50 extra) to keep the TV working? And are you, at that time, going to try to make me pay the £13.50 for the BT sport that I don't want?
    What do we do? Because I am sick to death of trying to communicate with people in India. They're lovely, but they really don't understand me when I'm rabbitting down the phone 100 miles per hour because I'm wound up at having to explain the same thing over and over. Why can't we just email you? Or is this a job for the Ombudsman. This is really poor service.

    the ombudsman does not deal with individual complains although they would take a note of your pronlem
    only people that can help here are the forum mods who are BT employees  they will post a contact us link 
    After completing the email NOT PM then you join a queue of other customers waiting for mod help. The mods will get back to you in 3/5 working days either by phone or email
    If you like a post, or want to say thanks for a helpful answer, please click on the Ratings star on the left-hand side of the post.
    If someone answers your question correctly please let other members know by clicking on ’Mark as Accepted Solution’.

  • Manual Updation of Ship to Partner (Customer) in Purchase order Item

    Hello Sap Gurus,
    While creating Purchase order (ME21n) of Type RTN or STO, the client wishes to Select the Ship to partner manually if more than 1 Ship to Partner is assigned to the Customer Master Data / Sales Organisation. Currently this is auto picked by SAP and the field is uneditable.
    I Have added the Functionality to PO Header to show the additional ship to partners in a drop down through use of enhancements. On selection of one of the ship to partners in PO header the Customer in Shipping Tab in all the PO items and Corresponding Delivery Addresses needs to be updated based on the selection.
    SAP Note 303453 shows how to change selected shipping data fields but not the customer or shipping address. My requirement is somewhat described by Note 652763 but that cannot be used in ME21n.
    Kindly help in this regard on how to achieve the functionality.

    Hello Helena,
    Unfortunately there is not possible to get the partner determination on the item level in the standard. The Partner determination in the standard system will be done on the header level only.
    The another thing is that if you change the partner (exept the  sold-to partner) in the sales order no new partner determination runs. It is the standard. Please also review the note 380507 (points 1 and 2).
    Best regards,
    Lela

  • Creation of a new order type

    Hello,
    Which are the impact on FI-CO module of the creation of a new order type to create a sales order?
    Thanks a lot.
    Emanuela

    Hi Emanuela,
    When production is based on sales order ( i.e Product cost by Sales order) in this scenario
    sales order is created as a cost object.
    This sales order is referenced when we create Cost estimate structure in CK51N
    In this way sales order is integrated with Product cost controlling in CO module.
    If your question is not answered, then give specific details about your requirement.
    With Regards
    AKBAR

  • Change of partner analyse in sales orders

    Hello,
    I changed the partner analyse for sales orders and added a new mandatory partnerrole.
    In new documents the partner analyse works fine, but in the existed sales documents I cant´t see, that a mandotory role is missing.
    How can I see that this role is missing in the exsting documents???
    Thanks for info
    Nicole

    You can create a custom report but there is no standard way to do this.
    When a document is created in SAP, it is a "snapshot" of that configuration, master data, and information as it exists when the document is created.  On the SD side there are a few things you can influence, for example, SAP contains some standard tools for mass updating of pricing information.  Most of the document exists in its unchanged state though. 
    You *may* be able to use VA05 and do this (although I doubt it, no system in front of me right now).  Other than that transaction or a custom report there really aren't a lot of options.
    If you are familiar enough with the tables, you can do a "quick view" or an ABAP Query to get the info.  However the SAP partner table is recursive so to avoid getting lots and lots of duplicates you will either have to add some code to a full query, or do offline manipulation of the data.
    If you're looking for soild SAP experience to help through some of these hurdles, please contact me.
    Bill Wood - President
    R3Now Consulting
    http://www.r3now.com SAP thought leadership!
    Platinum SAP Solutions
    (704) 905 - 5175
    http://www.linkedin.com/in/billwood

  • BADI or Exit for Partner Change in Sales order VA01,VA02

    Hi All,
    Please provide me with exit or badi to change the partner details(sold to , ship to , bill to etc...) before saving the sales order.
    I have tried to use 'MV45AFZZ' and treid to change XVBPA table but even though I update this internal table data is not getting updated into VBPA table of the database.
    Please help me out in this.
    thanks,
    Ayesha.

    Hi Valter,
    My requirement is whenever i change ship to party in sales order , bill to and payer need to be redetermined from ship to instead of sold to (as the standard does). I am doing this in MV45AFZZ. But I can see them updated in VBPA.
    But can see it in transaction as exit is triggering each time.
    suggest an alternative....
    thanks
    ayesha.

Maybe you are looking for

  • Sharing aliases with family members

    I have 5 aliases and would like to share them with my family. I would like to my family members to only receive and send using their respective emails (using their alias) on their iPads/iphones. Is that possible?

  • How to install internet explorer 8 in windows 8 pc.

    how to install internet explorer 8 in windows 8 pc.

  • Installation of Oracle Discoverer on Windows

    Hi All I need to install Oracle Discoverer Desktop on windows platform if any one has detail installation documentation of this please give me the link ASAP as i m never installed this discoverer on windows i m doing it first time i know how to insta

  • ITunes keeps losing my library

    Hi folks! I just added a time capsule to my home and moved my itunes library to it from my 2011 iMac. Every time I close and openTunes it asks were the library is located, what gives? Thanks in advance for the help!!

  • How do I unlock the iMac? The entire computer is locked.

    My wife was using Mail, she selected an item and the cursor changed from an arrow to the capital "I" and then would highlight all of the text in the email. I wnt down and right clicked on Mail to force quit. That sent the mail tool away but then ever