Tuesday, 28 August 2012

CUSTOMER API FOR CREATE LOCATION

Create a Location

=======================================================================

DECLARE
p_location_rec HZ_LOCATION_V2PUB.LOCATION_REC_TYPE;
x_location_id NUMBER;
x_return_status VARCHAR2(2000);
x_msg_count NUMBER;
x_msg_data VARCHAR2(2000);
BEGIN
p_location_rec.country := ’US’;
p_location_rec.address1 := ’300 Oracle Parkway’;
p_location_rec.address2 := ’13th Floor’;
p_location_rec.city := ’Redwood Shores’;
p_location_rec.postal_code := ’94065’;
p_location_rec.state := ’CA’;
p_location_rec.created_by_module := ’TCA_EXAMPLE’;
hz_location_v2pub.create_location(
’T’,
p_location_rec,
x_location_id,
x_return_status,
x_msg_count,
x_msg_data);
dbms_output.put_line('location id '||x_location_id);

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

============================================================================================

The above API shall create an address record in hz_locations table

No comments:

Post a Comment

AP Invoice Notes related Table details in Oracle Fusion

 What is the table that stores the AP Invoice notes? AP notes are stored in ZMM_NOTES table with SOURCE_OBJECT_CODE = 'AP_STANDARD_INVOI...