Create Location Assignment API

TCA Create Location Assignment API

Name of the API : UPDATE CUSTOMER PROFILE
Base Tables Affected : HZ_LOC_ASSIGNMENTS
PL/SQL Procedure used : CREATE_LOC_ASSIGNMENT
Package Used : HZ_TAX_ASSIGNMENT_V2PUB
Mandatory Parameters :
Parameter Name Parameter Type Data Type
p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE
p_location_id IN NUMBER
p_lock_flag IN VARCHAR2:= FND_API.G_FALSE
p_created_by_module IN VARCHAR2
p_application_id IN NUMBER
x_return_status IN OUT VARCHAR2,
x_msg_count OUT NUMBER
x_msg_data OUT VARCHAR2
x_loc_id OUT NUMBER

Procedure:

 General Tips for Running the Create Location Assignment API:

a) Save the API in a script file and then run the script from the SQL Prompt (Example : RUN create_loc_assignment.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 value of the Parameter Location_Id as a value which exists in HZ_LOCATIONS table.

Example For Running Create Location Assignment API:

 Sample Output of the Create Location Assignment Script:

x_return_status = S
Location Id = 29266
Created By Moudle = TCA_V2_API
x_msg_count = 0
x_msg_data =

Script To Verify whether the Create Location Assignment API is successful:

 

Leave a Reply