Create Contact details @ Customer Account Site

Hi guys
After loads of efforts I managed to create a contact @ Customer Account Site level using below API Call
DECLARE
p_cr_cust_acc_role_rec HZ_CUST_ACCOUNT_ROLE_V2PUB.cust_account_role_rec_type;
x_cust_account_role_id NUMBER;
x_return_status VARCHAR2(2000);
x_msg_count NUMBER;
x_msg_data VARCHAR2(2000);
BEGIN
-- NOTE:
-- must be unique CUST_ACCOUNT_ID, PARTY_ID,ROLE_TYPE
-- must be unique CUST_ACCT_SITE_ID, PARTY_ID,ROLE_TYPE
p_cr_cust_acc_role_rec.party_id := 2126134; --value for party_id from step 8>
p_cr_cust_acc_role_rec.cust_account_id := 999059; --value for cust_account_id from step 2>
p_cr_cust_acc_role_rec.primary_flag := 'Y';
p_cr_cust_acc_role_rec.role_type := 'CONTACT';
p_cr_cust_acc_role_rec.created_by_module := 'TCA_V2_API';
---For attaching the contact to a particular site
p_cr_cust_acc_role_rec.cust_acct_site_id := 29422; --Value for x_cust_acct_site_id from step >5
HZ_CUST_ACCOUNT_ROLE_V2PUB.create_cust_account_role(
'T',
p_cr_cust_acc_role_rec,
x_cust_account_role_id,
x_return_status,
x_msg_count,
x_msg_data);
dbms_output.put_line('***************************');
dbms_output.put_line('Output information ....');
dbms_output.put_line('***************************');
dbms_output.put_line('x_cust_account_role_id: '||x_cust_account_role_id);
dbms_output.put_line('x_return_status: '||x_return_status);
dbms_output.put_line('x_msg_count: '||x_msg_count);
dbms_output.put_line('x_msg_data: '||x_msg_data);
dbms_output.put_line('***************************');
IF x_msg_count >1 THEN
  FOR I IN 1..x_msg_count
   LOOP
    dbms_output.put_line(I||'. '||SubStr(FND_MSG_PUB.Get(p_encoded => FND_API.G_FALSE ), 1, 255));
  END LOOP;
END IF;
    IF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
COMMIT;
ELSE
ROLLBACK;
END IF;
END;
Now I want to attach "Address/Email/Phone number" to this contact @ the Account site level. Please let me know how and which APIs I need to call
Regards,
Raj

Okay I found the solution.
Reference material : How to Create Contact,Phone, Email under Communication tab for Customer Account Site using API [ID 985500.1]
docs.oracle.com/cd/B34956_01/current/acrobat/120hztig.pdf
Repeat Run --3. Create a physical location with customer account site level Address (ie, Specific contact address details). Note down x_location_id value
GET "x_party_id: " from "--8. Create a relation cont-org using party_id from step 7 and party_id from step 2"
Now Run "--4. Create a party site using party_id from step 2 and location_id from step 3" passing "x_party_id" from Step 8 & x_location_id from Step 3
Commit the changes and you will able to populate the account site specific contact person details
Regards,
rajesh

Similar Messages

  • R12: How to create Customer contact at party/account-site level

    Hello,
    I am working on a customer conversion where the legacy system stores customer contact at the address id (i.e. party site) level.
    Using various HZ APIs I have been able to create a party, customer account, location, party site, account site and account site use.
    Now, I want to create contacts at the party site or account site level. Which API is used to create a contact? (I found a note 985500.1 but it shows creation of contact point such as a phone number or email but not the contact itself).
    Any pointers appreciated.
    Manish

    HZ_PARTY_CONTACT_V2PUB

  • Error while creating customer account sites

    I am creating Customer Account Sites using the TCA API from Toad.
    I am getting the following error
    The operating unit is either invalid or it cannot be derived. Please verify your Multi-Org profile options.
    The Operating unit has been defined.
    I am using the following code:
    DECLARE
    p_cust_acct_site_rec hz_cust_account_site_v2pub.cust_acct_site_rec_type;
    x_return_status VARCHAR2(2000);
    x_msg_count NUMBER;
    x_msg_data VARCHAR2(2000);
    x_cust_acct_site_id NUMBER;
    BEGIN
    p_cust_acct_site_rec.cust_account_id := 9462;
    p_cust_acct_site_rec.party_site_id := 5473;
    --p_cust_acct_site_rec.language := 'US';
    p_cust_acct_site_rec.org_id := 126;
    p_cust_acct_site_rec.created_by_module := 'TCA-EXAMPLE';
    hz_cust_account_site_v2pub.create_cust_acct_site(
    'T',
    p_cust_acct_site_rec,
    x_cust_acct_site_id,
    x_return_status,
    x_msg_count,
    x_msg_data);
    dbms_output.put_line(SubStr('x_return_status =
    '||x_return_status,1,255));
    dbms_output.put_line('x_msg_count = '||TO_CHAR(x_msg_count));
    dbms_output.put_line(SubStr('x_msg_data = '||x_msg_data,1,255));
    IF x_msg_count >1 THEN
    FOR I IN 1..x_msg_count
    LOOP
    dbms_output.put_line(I||'. '||SubStr(FND_MSG_PUB.Get(p_encoded =>
    FND_API.G_FALSE ), 1, 255));
    END LOOP;
    END IF;
    END;
    Thanks and Regards,
    K tanna

    Hi,
    Please mention the application release along with the database version and OS.
    Please see if ('Change PO API' Errors with 'Multi-Org profile options' as Org Context Is Not Set Correctly [ID 732671.1]) helps.
    More details about setting the application context can be found in these docs.
    Note: 209185.1 - How To Set the Applications Context (FND_GLOBAL.APPS_INITIALIZE)
    Note: 420787.1 - Oracle Applications Multiple Organizations Access Control for Custom Code
    Note: 462383.1 - SQL Queries and Multi-Org Architecture in Release 12
    Note: 165042.1 - FAQ - Multiple Organizations Architechure (Multi-Org)
    Thanks,
    Hussein

  • Create Customer Account Site fail ORA-01400

    When creating customer account site in Oracle EBS r12.0.4, Error occur:
    The following SQL error occurred: ORA-01400: cannot insert NULL into ("AR"."HZ_CUST_ACCOUNTS_M"."CUSTOMER_MERGE_HEADER_ID").
    Can anyone help me solve this problem?
    Thanks in advanced!

    How do you create the customer account? From the application (if yes, mention the Navigation Path) or using an API (mention the API)?
    The following SQL error occurred: ORA-01400: cannot insert NULL into ("AR"."HZ_CUST_ACCOUNTS_M"."CUSTOMER_MERGE_HEADER_ID").Does this happen when creating any customer account or with specific ones only?
    Are you passing all the mandatory fields when creating the custom account?
    Obtain the FRD log for details about the error.
    Thanks,
    Hussein

  • Error while creating customer account sites from backend

    I am creating Customer Account Sites using the TCA API from Toad.
    I am getting the following error
    The operating unit is either invalid or it cannot be derived. Please verify your Multi-Org profile options.
    The Operating unit has been defined.
    I am using the following code:
    DECLARE
    p_cust_acct_site_rec hz_cust_account_site_v2pub.cust_acct_site_rec_type;
    x_return_status VARCHAR2(2000);
    x_msg_count NUMBER;
    x_msg_data VARCHAR2(2000);
    x_cust_acct_site_id NUMBER;
    BEGIN
    p_cust_acct_site_rec.cust_account_id := 9462;
    p_cust_acct_site_rec.party_site_id := 5473;
    --p_cust_acct_site_rec.language := 'US';
    p_cust_acct_site_rec.org_id := 126;
    p_cust_acct_site_rec.created_by_module := 'TCA-EXAMPLE';
    hz_cust_account_site_v2pub.create_cust_acct_site(
    'T',
    p_cust_acct_site_rec,
    x_cust_acct_site_id,
    x_return_status,
    x_msg_count,
    x_msg_data);
    dbms_output.put_line(SubStr('x_return_status =
    '||x_return_status,1,255));
    dbms_output.put_line('x_msg_count = '||TO_CHAR(x_msg_count));
    dbms_output.put_line(SubStr('x_msg_data = '||x_msg_data,1,255));
    IF x_msg_count >1 THEN
    FOR I IN 1..x_msg_count
    LOOP
    dbms_output.put_line(I||'. '||SubStr(FND_MSG_PUB.Get(p_encoded =>
    FND_API.G_FALSE ), 1, 255));
    END LOOP;
    END IF;
    END;
    Thanks and Regards,
    K tanna

    Duplicate post.
    Error while creating customer account sites
    Error while creating customer account sites

  • Error While Creating Customer Account Site.

    Hi ,
    I am creating a customer thru API's.
    I am succesffuly creating location,party,party site,party site use,customer account.But unable to create customer account site. I am getting the below error:
    Unable to process your transaction. The operating unit is either invalid or it cannot be derived. Please verify your Multi-Org profile options.
    Could anyone help me to resolve out this issue.

    Hi,
    What is the application release?
    Did you set the Application/Multi-org context properly before using this API?
    Note: 732671.1 - 'Change PO API' Errors with 'Multi-Org profile options' as Org Context Is Not Set Correctly
    Note: 420787.1 - Oracle Applications Multiple Organizations Access Control for Custom Code
    Note: 209185.1 - How To Set the Applications Context (FND_GLOBAL.APPS_INITIALIZE)
    Regards,
    Hussein

  • How to attach a Contact at Customer Account Level.

    Hi All,
    I want to know how to attach a contact at customer Account Level. Please let us know the API for the same.
    Or share some sample code if any.
    Thanks in advance.

    Hi,
    Are you using R11 or R12?
    Well i have an API that i used in R11 for the creation of contacts:
    hz_party_contact_v2pub.create_org_contact
    hz_contact_point_v2pub.create_contact_point
    Hope this helps you..
    Vik

  • Customer Account Sites page behavior

    Hi
    I am novice to OAF. I will take my best shot to explain the problem.
    Oracle Applications : 12.0.4
    Problem : Customer Account Sites page is displaying account sites in DESCENDING order of PURPOSES instead of ASCENDING.
    All the times, account sites were displayed in Ascending order of purposes. This will list Bill-To sites first and then 'Ship-To'. All of a sudden, account sites are started showing in reverse order listing 'Ship-To' first and then 'Bill-To'.
    There are no customizations, patches, personalizations applied to this form.
    Same form works in all other instances other than Production as expected (listing Bill-To sites first).
    What could be the reason so that sorting order of data element PURPOSES to change from Ascending to Desending? How to fix it?
    Please help.
    Regards,

    This is happening for all users.
    As a work around... User are using either clicking on Purpose column to sort again or filtering out 'Bill-To' sites. This is causing them irritation.
    Regards,

  • Creating a new customer account group

    Hi all,
    Can anyone please help me in this regard?
    I want to create a new  customer account group for a new customer( using T code XD01/VD01). Like say a new group called  " Sold to Party Samuel" .How to do that?
    I want to get the " Sold to Party Samuel" option in the drop down menu in the Account Group in the Customer create window which i get by using the T.code VD01 or XD01.
    I have tried lots of tips from websites  one of which I am stating below but none of that worked!! ->
    Path:
    (T.Code : OBD4) IMG - Financial Accounting - Master Records -Preparation - Define Account group- New Entries ,
    then a window opens up with columns
    Chrt/Accts |Acct Grp | Name|From Acc | To Acc .
    Then i am clueless what to do?
    And is this the way Account groups are created?
    Hope you all get me.
    Eagerly waiting for your reply.
    Thanks in advance

    <<Text copied from http://help.sap.com/bestpractices/bblibrary/documentation/j03_bb_configguide_en_br.doc >>
    Edited by: Matt on Aug 23, 2010 2:33 PM

  • IStore: Customer account sites with multiple price list

    Hi,
    We have an account with many sites, each site uses different price list. Say 1 site uses FR price list other uses GR price list.
    Users are suppose to use specific price list only. How can we have the users use their specific price list.
    Thanks in Advance

    Hi,
    For iStore you can setup specialty site based price lists and/or customer account level price lists.
    To setup the customer account level price lists -
    Set the profile option "IBE: Use Customer Account Price List" at the site level to Yes.
    Link the customer to the price list -
    1. Login to Oracle Forms and select Receivables Manager responsibility.
    2. Navigate to Customers > Standard.
    3. Select an account based on Customer Name, Account Number, or Organization Number.
    4. Press the Find button and select an address from the popup window; select Ok.
    5. Select the Order Management tab.
    6. Enter the appropriate price list in the Price List field, and save the form.
    7. Bounce the middle-tier and Web Cache servers.
    Reference:
    Oracle iStore Implementation and Administration Guide Release 12.1 (Part No. E13575-06)
    Chapter 10 Implementing Pricing
    Page 10-21
    Section Implementing Customer Account Price Lists
    OR
    You can setup modifiers for Customer (ie Customer Name) and Store (Minisite_ID) on the price list(s)
    For this setup you would need to set both "IBE: Use Customer Account Price List" and "IBE: Use Price List Associated with Specialty Site" to No.
    Thank you,
    Deborah
    Edited by: user702249 on Apr 10, 2013 6:56 PM

  • FM to upload Customer master Contact details.......

    Hello frndz,
      Is there any FM to upload Customer master Contact details.......
    regards,
    ajit.

    Hi Ajit,
    To upload the customer master contact details ,
    use the FM BAPI_PARTNEREMPLOYEE_CREATE.
    And to update the already created contact details,
    use the FM BAPI_ADDRESSCONTPART_CHANGE .
    also see link.
    Help with function mocule BAPI_ADDRESSCONTPART_CHANGE
    Thanks,
    Kanishak
    Do contact if any more quiries

  • Create CRM customer/account hierarchy node thru abap code

    Hi,
    Any one can help me on how to Create CRM customer/account hierarchy node thru abap code?
    Is there any Class/methods, FMs that I can use to create node in customer/account hierarchy?
    Sample codes will greatly help me.
    I hope someone can help me on this since this is my urgent requirements on my project.
    Thanks,
    james

    James,
    You can find the FM, Class Lib and APIs under the package BUPA_HIERARCHY.

  • Credit contorl of Customer Account Group

    Dear All,
    My exact requirement is we are going to create a New Customer Account Group. Whoever the customers are there in this customer group the CREDIT LIMIT should be One Rupee as a default. It should not be changeable.
    Whenever User wants try to change the Credit Limit system should not allow.
    Is it possible by transaction Code FD32 or is there any other way?
    Kindly help me out.
    Thanks & Regards,
    Yadayya

    Dear Farooq,
    It seems it may useful to resolve my requirement. But i am not able to understand how to do the configuration before asking Basis person.
    My requirement that restriction should be applicable to all the customers who will come under one Customer Account Group which we are going to create as new. IT SHOULD NOT EFFECT OTHER CUSTOMER ACCOUNT GROUPS.
    Kindly explain me clearly so that i can resolve my issue.
    Thanks for your kind help.
    Thanks & Regards,
    Yadayya

  • How to view List of Customer Account Groups

    T-Code OBD2  to create a new Customer Account Group.
    To avoid using an existing name, i would like to have an idea about the current existing Group  names .
    What is the T-Code to view that list ?

    Hi Mr. Emad
    you question is fully clear..  but you can see all existing names of the account group for customer at the creation screen for new customer T-code XD01  like below attached
    Regards
    Mahmoud El Nady

  • Customer conversion - automatically populate the Contact details of the Customer at site Level

    Hi
    Requirement is to populate the Contact details of the Customer at site Level.
    I could't find the API where site_id , contact details can be passed, so that data will be automatically display.
    Please suggest the process for this.
    Thanks.

    Hi,
    Please review the following MOS doc. for the same.
    Technical Uses of Customer Interface and TCA-API [ID 269121.1]
    Using TCA API's Including Examples [ID 201243.1]    
    Customer Account Creation Using TCA APIs [837568.1]
    Oracle Trading Community: TCA API Overview, Setup, Sample Scripts and Troubleshooting (Doc ID 1637029.2)

Maybe you are looking for

  • Call Custom Library built in type is not available in form personalization.

    Hello All, In our Vision instance(EBS 11.5.10.2 Dev 6i Patchset 15) Call Custom Library built in type is not available in form personalization.. Please suggest

  • IQ524 Upgrade to win 7 problems

    Still unresolved problems with win7 upgrade and after 5 weeks of attempting to get through on the help line showing on the instructions still no results.  Now when you call the help line it says it is a private number.  What is that all about.  This

  • Folders For DVD-ROM Content?

    Hey all - when adding DVD-ROM content, am I limited to dumping all of the files into one directory, or can I use a folder structure? For example, I'd like my DVD-ROM selections to include pictures, mp3's, and wallpapers, with each of those housed in

  • CF8 read FMS shared objects

    How can I have CF8 Standard (w/out Flex) read a Flash Media Server shared object?  I just need to read it; there will be no modifications to the shared object.

  • Where is the complete list of what does and doesn't get backed up on iOS?

    I found a webpage from Macworld pointing to Back up and restore your iPhone, iPad, or iPod touch using iCloud or iTunes - Apple Support as giving a complete list of what does and does not get backed up in the iPhone backup.  This page must have chang