DBA Data[Home] [Help]

APPS.DPP_CLAIMS_PVT dependencies on DPP_CUSTOMER_CLAIMS_GT

Line 136: FROM DPP_CUSTOMER_CLAIMS_GT

132: j NUMBER;
133:
134: CURSOR get_claim_hdr_amt_pd_csr(p_currency_code IN VARCHAR2) IS
135: SELECT SUM(DPP_UTILITY_PVT.CurrRound(claim_line_amount, p_currency_code)) amount
136: FROM DPP_CUSTOMER_CLAIMS_GT
137: where claim_line_amount > 0;
138:
139: CURSOR get_claim_hdr_amt_pi_csr(p_currency_code IN VARCHAR2) IS
140: SELECT SUM(DPP_UTILITY_PVT.CurrRound(ABS(claim_line_amount), p_currency_code)) amount

Line 141: FROM DPP_CUSTOMER_CLAIMS_GT

137: where claim_line_amount > 0;
138:
139: CURSOR get_claim_hdr_amt_pi_csr(p_currency_code IN VARCHAR2) IS
140: SELECT SUM(DPP_UTILITY_PVT.CurrRound(ABS(claim_line_amount), p_currency_code)) amount
141: FROM DPP_CUSTOMER_CLAIMS_GT
142: where claim_line_amount < 0;
143:
144: CURSOR get_claim_id_csr (p_line_id IN NUMBER) IS
145: SELECT claim_id

Line 146: FROM DPP_CUSTOMER_CLAIMS_GT

142: where claim_line_amount < 0;
143:
144: CURSOR get_claim_id_csr (p_line_id IN NUMBER) IS
145: SELECT claim_id
146: FROM DPP_CUSTOMER_CLAIMS_GT
147: WHERE Transaction_Line_ID = p_line_id;
148:
149: CURSOR grpby_currency_csr IS
150: SELECT SUM(Claim_Line_Amount) amount,

Line 152: FROM DPP_CUSTOMER_CLAIMS_GT

148:
149: CURSOR grpby_currency_csr IS
150: SELECT SUM(Claim_Line_Amount) amount,
151: Currency
152: FROM DPP_CUSTOMER_CLAIMS_GT
153: GROUP BY Currency;
154:
155: CURSOR get_claim_lines_csr (p_currency IN VARCHAR2) IS
156: SELECT transaction_line_id,

Line 163: FROM DPP_CUSTOMER_CLAIMS_GT

159: inventory_item_id,
160: claim_quantity,
161: item_description,
162: uom
163: FROM DPP_CUSTOMER_CLAIMS_GT
164: WHERE currency = p_currency;
165:
166: CURSOR grpby_cur_cust_csr IS
167: SELECT SUM(Claim_Line_Amount) amount,

Line 171: FROM DPP_CUSTOMER_CLAIMS_GT

167: SELECT SUM(Claim_Line_Amount) amount,
168: Currency,
169: customer_id,
170: cust_account_id
171: FROM DPP_CUSTOMER_CLAIMS_GT
172: GROUP BY Currency,
173: customer_id,
174: cust_account_id;
175:

Line 186: FROM DPP_CUSTOMER_CLAIMS_GT

182: inventory_item_id,
183: claim_quantity,
184: item_description,
185: uom
186: FROM DPP_CUSTOMER_CLAIMS_GT
187: WHERE currency = p_currency
188: AND customer_id = p_customer_id
189: AND cust_account_id = p_cust_account_id;
190:

Line 308: -- Delete the existing lines if any from the DPP_CUSTOMER_CLAIMS_GT temporary table

304: ELSE
305: j := 1;
306: END IF;
307:
308: -- Delete the existing lines if any from the DPP_CUSTOMER_CLAIMS_GT temporary table
309: DELETE FROM DPP_CUSTOMER_CLAIMS_GT;
310:
311: l_price_increase_flag := NULL;
312: FOR k in 1..j LOOP

Line 309: DELETE FROM DPP_CUSTOMER_CLAIMS_GT;

305: j := 1;
306: END IF;
307:
308: -- Delete the existing lines if any from the DPP_CUSTOMER_CLAIMS_GT temporary table
309: DELETE FROM DPP_CUSTOMER_CLAIMS_GT;
310:
311: l_price_increase_flag := NULL;
312: FOR k in 1..j LOOP
313: IF j = 2 THEN --When transaction has both price increase and price decrease lines

Line 331: -- Delete the existing lines if any from the DPP_CUSTOMER_CLAIMS_GT temporary table

327: l_price_increase_flag := 'N';
328: END IF;
329: END IF;
330:
331: -- Delete the existing lines if any from the DPP_CUSTOMER_CLAIMS_GT temporary table
332: --DELETE FROM DPP_CUSTOMER_CLAIMS_GT;
333:
334: --Insert the lines into the global temp table
335: FOR i in l_txn_line_tbl.FIRST..l_txn_line_tbl.LAST LOOP

Line 332: --DELETE FROM DPP_CUSTOMER_CLAIMS_GT;

328: END IF;
329: END IF;
330:
331: -- Delete the existing lines if any from the DPP_CUSTOMER_CLAIMS_GT temporary table
332: --DELETE FROM DPP_CUSTOMER_CLAIMS_GT;
333:
334: --Insert the lines into the global temp table
335: FOR i in l_txn_line_tbl.FIRST..l_txn_line_tbl.LAST LOOP
336: BEGIN

Line 337: Insert into DPP_CUSTOMER_CLAIMS_GT(Transaction_Line_ID,

333:
334: --Insert the lines into the global temp table
335: FOR i in l_txn_line_tbl.FIRST..l_txn_line_tbl.LAST LOOP
336: BEGIN
337: Insert into DPP_CUSTOMER_CLAIMS_GT(Transaction_Line_ID,
338: Inventory_Item_Id,
339: cust_account_id,
340: Claim_Line_Amount,
341: Currency,

Line 369: UPDATE DPP_CUSTOMER_CLAIMS_GT

365: END;
366: --Get the item number
367: IF l_txn_line_tbl(i).inventory_item_id IS NOT NULL THEN
368: FOR get_item_number_rec IN get_item_number_csr(l_txn_line_tbl(i).inventory_item_id) LOOP
369: UPDATE DPP_CUSTOMER_CLAIMS_GT
370: SET item_number = get_item_number_rec.item_number,
371: item_description = get_item_number_rec.description
372: WHERE transaction_line_id = l_txn_line_tbl(i).transaction_line_id;
373: IF SQL%ROWCOUNT = 0 THEN

Line 374: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_EXCEPTION, l_module, 'Unable to Update the column item_number in DPP_CUSTOMER_CLAIMS_GT Table');

370: SET item_number = get_item_number_rec.item_number,
371: item_description = get_item_number_rec.description
372: WHERE transaction_line_id = l_txn_line_tbl(i).transaction_line_id;
373: IF SQL%ROWCOUNT = 0 THEN
374: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_EXCEPTION, l_module, 'Unable to Update the column item_number in DPP_CUSTOMER_CLAIMS_GT Table');
375: END IF;
376: END LOOP;
377: ELSE
378: FND_MESSAGE.set_name('DPP', 'DPP_API_INPUT_ID_MISSING');

Line 387: UPDATE DPP_CUSTOMER_CLAIMS_GT

383: --Get the customer name
384: IF l_txn_hdr_rec.claim_type_flag = 'CUST_CL' THEN
385: IF l_txn_line_tbl(i).cust_account_id IS NOT NULL THEN
386: FOR get_customer_dtl_rec IN get_customer_dtl_csr(l_txn_line_tbl(i).cust_account_id) LOOP
387: UPDATE DPP_CUSTOMER_CLAIMS_GT
388: SET customer_name = get_customer_dtl_rec.account_name,
389: customer_id = get_customer_dtl_rec.party_id
390: WHERE cust_account_id = l_txn_line_tbl(i).cust_account_id;
391: IF SQL%ROWCOUNT = 0 THEN

Line 392: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_EXCEPTION, l_module, 'Unable to Update the column customer_name in DPP_CUSTOMER_CLAIMS_GT Table');

388: SET customer_name = get_customer_dtl_rec.account_name,
389: customer_id = get_customer_dtl_rec.party_id
390: WHERE cust_account_id = l_txn_line_tbl(i).cust_account_id;
391: IF SQL%ROWCOUNT = 0 THEN
392: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_EXCEPTION, l_module, 'Unable to Update the column customer_name in DPP_CUSTOMER_CLAIMS_GT Table');
393: END IF;
394: END LOOP;
395: ELSE
396: FND_MESSAGE.set_name('DPP', 'DPP_API_INPUT_ID_MISSING');

Line 533: UPDATE DPP_CUSTOMER_CLAIMS_GT

529: fnd_message.set_token('ERRNO', sqlcode);
530: fnd_message.set_token('REASON', 'Error while Creating Claim in Trade Management');
531: FND_MSG_PUB.add;
532: --Update the GT table with the reason for failure
533: UPDATE DPP_CUSTOMER_CLAIMS_GT
534: SET reason_for_failure = nvl(substr(l_msg_data,1,4000),'Error while Creating Claim in Trade Management');
535: IF SQL%ROWCOUNT = 0 THEN
536: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update DPP_CUSTOMER_CLAIMS_GT Table');
537: END IF;

Line 536: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update DPP_CUSTOMER_CLAIMS_GT Table');

532: --Update the GT table with the reason for failure
533: UPDATE DPP_CUSTOMER_CLAIMS_GT
534: SET reason_for_failure = nvl(substr(l_msg_data,1,4000),'Error while Creating Claim in Trade Management');
535: IF SQL%ROWCOUNT = 0 THEN
536: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update DPP_CUSTOMER_CLAIMS_GT Table');
537: END IF;
538: ELSE
539: --Assign the claim id to the header record to call the update claim api
540: l_txn_hdr_rec.claim_id := l_x_claim_id ;

Line 589: UPDATE DPP_CUSTOMER_CLAIMS_GT

585: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
586: END;
587: --Insert the claim id into the global temp table..
588: IF l_price_increase_flag = 'Y' THEN
589: UPDATE DPP_CUSTOMER_CLAIMS_GT
590: SET claim_id = l_x_claim_id,
591: claim_number = l_claim_number
592: where claim_line_amount < 0;
593: ELSIF l_price_increase_flag = 'N' THEN

Line 594: UPDATE DPP_CUSTOMER_CLAIMS_GT

590: SET claim_id = l_x_claim_id,
591: claim_number = l_claim_number
592: where claim_line_amount < 0;
593: ELSIF l_price_increase_flag = 'N' THEN
594: UPDATE DPP_CUSTOMER_CLAIMS_GT
595: SET claim_id = l_x_claim_id,
596: claim_number = l_claim_number
597: where claim_line_amount > 0;
598: END IF;

Line 600: -- UPDATE DPP_CUSTOMER_CLAIMS_GT

596: claim_number = l_claim_number
597: where claim_line_amount > 0;
598: END IF;
599:
600: -- UPDATE DPP_CUSTOMER_CLAIMS_GT
601: -- SET claim_id = l_x_claim_id,
602: -- claim_number = l_claim_number;
603: IF SQL%ROWCOUNT = 0 THEN
604: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');

Line 604: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');

600: -- UPDATE DPP_CUSTOMER_CLAIMS_GT
601: -- SET claim_id = l_x_claim_id,
602: -- claim_number = l_claim_number;
603: IF SQL%ROWCOUNT = 0 THEN
604: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');
605: END IF;
606: --Assign the claim id to the corresponding lines
607: FOR i IN l_txn_line_tbl.FIRST..l_txn_line_tbl.LAST LOOP
608: --Insert into the output xml table to generate the error log

Line 705: UPDATE DPP_CUSTOMER_CLAIMS_GT

701: fnd_message.set_token('ERRNO', sqlcode);
702: fnd_message.set_token('REASON', 'Error while Updating Claim in Trade Management');
703: FND_MSG_PUB.add;
704: --Delete the claim numbers from the GT table
705: UPDATE DPP_CUSTOMER_CLAIMS_GT
706: SET claim_id = null,
707: claim_number = null;
708: IF SQL%ROWCOUNT = 0 THEN
709: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update DPP_CUSTOMER_CLAIMS_GT Table');

Line 709: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update DPP_CUSTOMER_CLAIMS_GT Table');

705: UPDATE DPP_CUSTOMER_CLAIMS_GT
706: SET claim_id = null,
707: claim_number = null;
708: IF SQL%ROWCOUNT = 0 THEN
709: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update DPP_CUSTOMER_CLAIMS_GT Table');
710: END IF;
711: END IF;
712: END IF; --Pre approval is not required
713: END IF;

Line 771: UPDATE DPP_CUSTOMER_CLAIMS_GT

767: fnd_message.set_token('ERRNO', sqlcode);
768: fnd_message.set_token('REASON', 'Error while Creating Claim in Trade Management');
769: FND_MSG_PUB.add;
770: --Update the claim id into the global temp table..
771: UPDATE DPP_CUSTOMER_CLAIMS_GT
772: SET reason_for_failure = nvl(substr(l_msg_data,1,4000),'Error while Creating Claim in Trade Management')
773: WHERE currency = grpby_currency_rec.Currency;
774:
775: IF SQL%ROWCOUNT = 0 THEN

Line 776: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');

772: SET reason_for_failure = nvl(substr(l_msg_data,1,4000),'Error while Creating Claim in Trade Management')
773: WHERE currency = grpby_currency_rec.Currency;
774:
775: IF SQL%ROWCOUNT = 0 THEN
776: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');
777: END IF;
778: ELSE
779: --Update the claim to pending close status
780: --Call the update_claims procedure to update the claim status to open

Line 884: UPDATE DPP_CUSTOMER_CLAIMS_GT

880: END IF;
881: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
882: END;
883: --Update the claim id into the global temp table..
884: UPDATE DPP_CUSTOMER_CLAIMS_GT
885: SET claim_id = l_x_claim_id,
886: claim_number = l_claim_number
887: WHERE currency = grpby_currency_rec.Currency;
888:

Line 890: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');

886: claim_number = l_claim_number
887: WHERE currency = grpby_currency_rec.Currency;
888:
889: IF SQL%ROWCOUNT = 0 THEN
890: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');
891: END IF;
892: END IF; --Update claim call success
893: END IF; --Create claim success
894: END LOOP;

Line 984: UPDATE DPP_CUSTOMER_CLAIMS_GT

980: fnd_message.set_token('ERRNO', sqlcode);
981: fnd_message.set_token('REASON', 'Error while Creating Claim in Trade Management');
982: FND_MSG_PUB.add;
983: --Insert the claim id into the global temp table..
984: UPDATE DPP_CUSTOMER_CLAIMS_GT
985: SET reason_for_failure = nvl(substr(l_msg_data,1,4000),'Error while Creating Claim in Trade Management')
986: WHERE currency = grpby_cur_cust_rec.Currency
987: AND customer_id = grpby_cur_cust_rec.customer_id
988: AND cust_account_id = grpby_cur_cust_rec.cust_account_id;

Line 991: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');

987: AND customer_id = grpby_cur_cust_rec.customer_id
988: AND cust_account_id = grpby_cur_cust_rec.cust_account_id;
989:
990: IF SQL%ROWCOUNT = 0 THEN
991: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');
992: END IF;
993: ELSE
994: --Update the claim to Pending Close status
995: l_claim_pub_rec.claim_id := l_x_claim_id;

Line 1098: UPDATE DPP_CUSTOMER_CLAIMS_GT

1094: END IF;
1095: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1096: END;
1097: --Insert the claim id into the global temp table..
1098: UPDATE DPP_CUSTOMER_CLAIMS_GT
1099: SET claim_id = l_x_claim_id,
1100: claim_number = l_claim_number,
1101: reason_for_failure = nvl(substr(l_msg_data,1,4000),'Error while Updating Claim in Trade Management')
1102: WHERE currency = grpby_cur_cust_rec.Currency

Line 1106: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');

1102: WHERE currency = grpby_cur_cust_rec.Currency
1103: AND customer_id = grpby_cur_cust_rec.customer_id
1104: AND cust_account_id = grpby_cur_cust_rec.cust_account_id;
1105: IF SQL%ROWCOUNT = 0 THEN
1106: DPP_UTILITY_PVT.debug_message(FND_LOG.LEVEL_STATEMENT, l_module, 'Unable to Update the column claim_id in DPP_CUSTOMER_CLAIMS_GT Table');
1107: END IF;
1108: END IF;
1109: END IF;
1110: END LOOP;

Line 1161: FROM DPP_CUSTOMER_CLAIMS_GT) TRANSACTION

1157: l_status := 'SUCCESS';
1158: --Output XML Generation Code.
1159: l_queryCtx := dbms_xmlquery.newContext('SELECT '||l_transaction_number||'Txnnumber,
1160: CURSOR (SELECT DISTINCT claim_number claimnumber
1161: FROM DPP_CUSTOMER_CLAIMS_GT) TRANSACTION
1162: FROM dual');
1163: ELSE
1164: l_status := 'WARNING';
1165: --Output XML Generation Code.

Line 1172: FROM DPP_CUSTOMER_CLAIMS_GT) transaction FROM dual');

1168: customer_name customername,
1169: currency,
1170: item_number itemnumber ,
1171: reason_for_failure reason
1172: FROM DPP_CUSTOMER_CLAIMS_GT) transaction FROM dual');
1173: END IF;
1174: dbms_xmlquery.setRowTag(l_queryCtx
1175: ,'ROOT'
1176: );