TCA Create Person API

Create Person API

Name of the API : CREATE PERSON API
Base Tables Affected :

  • HZ_PARTIES
  • HZ_PERSON_PROFILES

PL/SQL Procedure used : CREATE_PERSON
Package Used : 

  • HZ_PARTY_V2PUB

Mandatory Parameters:

p_init_msg_list IN VARCHAR2:= FND_API.G_FALSE
p_person_rec IN PERSON_REC_TYPE
x_party_id OUT NUMBER,
x_party_number OUT VARCHAR2
x_prof i l e_i d OUT NUMBER
x_return_status OUT VARCHAR2
x_msg_count OUT NUMBER
x_msg_data OUT VARCHAR2

Procedure:

 General Tips for Running the Create Person API:

a) Save the API in a script file and then run the script from the SQL Prompt (Example : RUN createperson.sql)
b) Enter the values for the Parameters from inside the script file itself unless it is required to Enter some value from the SQL Prompt.
c) 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 mo_global.set_policy_context(‘S’, <org_id>);
d) Ensure that the Profile Option HZ : Generate Party Number is Set to ‘Yes’ at Site Level.

Code for Create Person API:

 Output of the Create Person Script:

x_return_status = S
x_msg_count = 0
Party Id = 546715
Party Number = 60415
Profile Id = 554833
x_msg_data =

Script To Verify whether the Create Person API is successful:

 

Related posts:

Leave a Reply