Create Customer Profile API

TCA Create Customer Profile API

Name of the API : CREATE CUSTOMER PROFILE
Base Tables Affected : HZ_CUSTOMER_PROFILES
PL/SQL Procedure used : CREATE_CUSTOMER_PROFILE
Package Used : HZ_CUSTOMER_PROFILE_V2PUB
Mandatory Parameters :
Parameter Name Parameter Type Data Type
p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE
p _ customer _prof ile_rec IN CUSTOMER_ PROFI LE_ REC_ TYPE
p_create_profil e_amt IN VARCHAR2:= FND_API. G_TRUE
x_cust_account_profile_id OUT NUMBER
x_return_status OUT VARCHAR2
x_msg_count OUT NUMBER
x_msg_data OUT VARCHAR2

Procedure:

 General Tips for Running the Create Customer Profile API:

a) Save the API in a script file and then run the script from the SQL Prompt (Example : RUN create_customer_profile.sql)
b) Set the organization id before running the script as :
EXEC fnd_client_info.set_org_context(‘<orgid>’); for 11i
OR For R12
EXEC mo_global.init (‘AR’);
EXEC mo_global.set_org_context(<org_id>, NULL, ‘AR’);
EXEC fnd_global.set_nls_context(‘AMERICAN’);
EXEC mo_global.set_policy_context(‘S’, <org_id>);
c) Enter the values for the Parameter cust_account_id from the SQL Prompt or from within API itself as a fixed value.
d) The Cust_Account_Id must exists in hz_cust_accounts and should not exists in hz_customer_profiles.

Example For Running Create Customer Profile API:

 Sample Output of the Create Customer Profile Script:

x_return_status = S
Cust Account Id = 4429
Cust Account Profile Id = 201877
Status =
Credit Checking =
Interest Charges =
x_msg_count = 0
x_msg_data =

Script To Verify whether the Create Customer Profile API is successful:

 

 

 

Related posts:

Leave a Reply