My Oracle Support Banner

Create Claims for Credit Memo Using OZF_CLAIM_PUB.CREATE_CLAIM API Error: "ORA-20010: GLMCCURBL This Transaction Cannot Be Processed" (Doc ID 1073570.1)

Last updated on SEPTEMBER 01, 2020

Applies to:

Oracle Trade Management - Version 12.0.0 to 12.1.2 [Release 12.0 to 12.1]
Information in this document applies to any platform.

Symptoms

ORA-20010: GLMCCURB error when running the OZF_CLAIM_PUB.CREATE_CLAIM API script.

Error

ORA-20010: GLMCCURB: This transaction cannot be processed because the transaction itself and/or its dependent 
open transactions have not been converted to all the associated reporting currencies required. 
If you just upgraded from a prior in Package OZ


Steps to Reproduce

Ran Script


set serveroutput on

DECLARE
l_return_status VARCHAR2 (1);
l_msg_count NUMBER;
l_msg_data VARCHAR2 (20000);
l_resp_name VARCHAR2 (100) := 'Oracle Trade Management User';
l_user_name VARCHAR2 (100) := 'TRADEMGR';
--'AVAGNER';
l_appl_short_name VARCHAR2 (100);
l_appl_id NUMBER;
l_resp_id NUMBER;
l_user_id NUMBER;
l_org_id NUMBER;
l_claim_pub_rec ozf_claim_pub.claim_rec_type;
--l_claim_line_pub_tbl(0) ozf_claim_pub.claim_line_rec_type;
l_claim_line_pub_tbl ozf_claim_pub.claim_line_tbl_type;
l_claim_line_count NUMBER := 0;
l_x_claim_id NUMBER;
BEGIN
------------------------------------------
-- Initialization
------------------------------------------
SELECT fa.application_id, responsibility_id, fa.application_short_name
INTO l_appl_id, l_resp_id, l_appl_short_name
FROM fnd_responsibility_vl fr, fnd_application fa
WHERE responsibility_name = l_resp_name
AND fr.application_id = fa.application_id;

SELECT user_id
INTO l_user_id
FROM fnd_user
WHERE user_name = l_user_name;

--- Below apps_initialize Needed to be commeented. So Claim can get created.
-- Successfully created claim after commenting apps_initialize
--Success with Claim header and claim Line both.
--fnd_global.apps_initialize (l_user_id, l_resp_id, l_appl_id);
mo_global.init ('AR');
mo_global.set_policy_context ('S', 204);


--- Claim Header Records
-- 1. assign value for claim rec
l_claim_pub_rec.claim_number := 'Test100';
l_claim_pub_rec.cust_account_id := 1317;
l_claim_pub_rec.claim_class := 'CHARGE';--'CLAIM';
l_claim_pub_rec.amount := -4288.82;
l_claim_pub_rec.gl_date := SYSDATE;
l_claim_pub_rec.acctd_amount := -4288.82;
l_claim_pub_rec.status_code := 'NEW';
l_claim_pub_rec.user_status_id := 2001;
l_claim_pub_rec.claim_type_id := 6;
l_claim_pub_rec.reason_code_id := 5;
l_claim_pub_rec.org_id := fnd_global.org_id;
l_claim_pub_rec.last_update_date := SYSDATE;
l_claim_pub_rec.last_updated_by := l_user_id;
l_claim_pub_rec.creation_date := SYSDATE;
l_claim_pub_rec.created_by := l_user_id;
l_claim_pub_rec.claim_date := SYSDATE;
l_claim_pub_rec.amount_remaining := -4288.82;
l_claim_pub_rec.currency_code := 'USD';
--l_claim_pub_rec.set_of_books_id := 1;
--l_claim_pub_rec.exchange_rate := 1;

--- Claim Line Records
l_claim_line_pub_tbl (1).claim_line_id := ozf_claim_lines_all_s.nextval;
l_claim_line_pub_tbl (1).object_version_number := 1.0;
l_claim_line_pub_tbl (1).last_update_date := SYSDATE;
l_claim_line_pub_tbl (1).last_updated_by := l_user_id;
l_claim_line_pub_tbl (1).creation_date := SYSDATE;
l_claim_line_pub_tbl (1).created_by := l_user_id;
l_claim_line_pub_tbl (1).claim_id := l_x_claim_id;
l_claim_line_pub_tbl (1).line_number := 1;
l_claim_line_pub_tbl (1).amount := l_claim_pub_rec.amount;
l_claim_line_pub_tbl (1).claim_currency_amount := l_claim_pub_rec.acctd_amount;
l_claim_line_pub_tbl (1).acctd_amount := l_claim_pub_rec.acctd_amount;
l_claim_line_pub_tbl (1).set_of_books_id := l_claim_pub_rec.set_of_books_id;
l_claim_line_pub_tbl (1).source_object_id := 6753;
l_claim_line_pub_tbl (1).source_object_class := 'CM';
l_claim_line_pub_tbl (1).org_id := fnd_global.org_id;
-- 3. create claim
ozf_claim_pub.create_claim
(p_api_version_number => 1.0,
p_init_msg_list => fnd_api.g_true,
p_commit => fnd_api.g_false,
p_validation_level => fnd_api.g_valid_level_full,
x_return_status => l_return_status,
x_msg_count => l_msg_count,
x_msg_data => l_msg_data,
p_claim_rec => l_claim_pub_rec,
p_claim_line_tbl => l_claim_line_pub_tbl,
x_claim_id => l_x_claim_id
);
DBMS_OUTPUT.put_line ('Success ? ' || l_return_status);
DBMS_OUTPUT.put_line ('Claim ID = ' || l_x_claim_id);
fnd_msg_pub.count_and_get (p_encoded => fnd_api.g_false,
p_count => l_msg_count,
p_data => l_msg_data
);

FOR i IN 1 .. l_msg_count
LOOP
DBMS_OUTPUT.put_line (SUBSTR (fnd_msg_pub.get (p_msg_index => i,
p_encoded => 'F'
),
1,
254
)
);
END LOOP;

DBMS_OUTPUT.put_line ('========= END =========');
END;
/

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.