DBA Data[Home] [Help]

PACKAGE BODY: APPS.OZF_CLAIMS_INT_PKG

Source


1 PACKAGE BODY OZF_CLAIMS_INT_PKG as
2 /* $Header: ozftcinb.pls 115.4 2004/07/05 08:50:26 upoluri ship $ */
3 -- ===============================================================
4 -- Start of Comments
5 -- Package name
6 --          OZF_CLAIMS_INT_PKG
7 -- Purpose
8 --
9 -- History
10 --
11 -- NOTE
12 --
13 -- End of Comments
14 -- ===============================================================
15 
16 
17 G_PKG_NAME CONSTANT VARCHAR2(30):= 'OZF_CLAIMS_INT_PKG';
18 G_FILE_NAME CONSTANT VARCHAR2(12) := 'ozftcinb.pls';
19 
20 
21 ----------------------------------------------------------
22 ----          MEDIA           ----
23 ----------------------------------------------------------
24 
25 --  ========================================================
26 --
27 --  NAME
28 --  createInsertBody
29 --
30 --  PURPOSE
31 --
32 --  NOTES
33 --
34 --  HISTORY
35 --
36 --  ========================================================
37 PROCEDURE Insert_Row(
38           px_interface_claim_id   IN OUT NOCOPY NUMBER,
39           px_object_version_number   IN OUT NOCOPY NUMBER,
40           p_last_update_date    DATE,
41           p_last_updated_by    NUMBER,
42           p_creation_date    DATE,
43           p_created_by    NUMBER,
44           p_last_update_login    NUMBER,
45           p_request_id    NUMBER,
46           p_program_application_id    NUMBER,
47           p_program_update_date    DATE,
48           p_program_id    NUMBER,
49           p_created_from    VARCHAR2,
50           p_batch_id    NUMBER,
51           p_claim_id    NUMBER,
52           p_claim_number    VARCHAR2,
53           p_claim_type_id    NUMBER,
54           p_claim_class    VARCHAR2,
55           p_claim_date    DATE,
56           p_due_date    DATE,
57           p_owner_id    NUMBER,
58           p_history_event    VARCHAR2,
59           p_history_event_date    DATE,
60           p_history_event_description    VARCHAR2,
61           p_split_from_claim_id    NUMBER,
62           p_duplicate_claim_id    NUMBER,
63           p_split_date    DATE,
64           p_root_claim_id    NUMBER,
65           p_amount    NUMBER,
66           p_amount_adjusted    NUMBER,
67           p_amount_remaining    NUMBER,
68           p_amount_settled    NUMBER,
69           p_acctd_amount    NUMBER,
70           p_acctd_amount_remaining    NUMBER,
71           p_tax_amount    NUMBER,
72           p_tax_code    VARCHAR2,
73           p_tax_calculation_flag    VARCHAR2,
74           p_currency_code    VARCHAR2,
75           p_exchange_rate_type    VARCHAR2,
76           p_exchange_rate_date    DATE,
77           p_exchange_rate    NUMBER,
78           p_set_of_books_id    NUMBER,
79           p_original_claim_date    DATE,
80           p_source_object_id    NUMBER,
81           p_source_object_class    VARCHAR2,
82           p_source_object_type_id    NUMBER,
83           p_source_object_number    VARCHAR2,
84           p_cust_account_id    NUMBER,
85           p_cust_billto_acct_site_id    NUMBER,
86           p_cust_shipto_acct_site_id    NUMBER,
87           p_location_id    NUMBER,
88           p_pay_related_account_flag    VARCHAR2,
89           p_related_cust_account_id    NUMBER,
90           p_related_site_use_id    NUMBER,
91           p_relationship_type    VARCHAR2,
92           p_vendor_id    NUMBER,
93           p_vendor_site_id    NUMBER,
94           p_reason_type    VARCHAR2,
95           p_reason_code_id    NUMBER,
96           p_task_template_group_id    NUMBER,
97           p_status_code    VARCHAR2,
98           p_user_status_id    NUMBER,
99           p_sales_rep_id    NUMBER,
100           p_collector_id    NUMBER,
101           p_contact_id    NUMBER,
102           p_broker_id    NUMBER,
103           p_territory_id    NUMBER,
104           p_customer_ref_date    DATE,
105           p_customer_ref_number    VARCHAR2,
106           p_assigned_to    NUMBER,
107           p_receipt_id    NUMBER,
108           p_receipt_number    VARCHAR2,
109           p_doc_sequence_id    NUMBER,
110           p_doc_sequence_value    NUMBER,
111           p_gl_date    DATE,
112           p_payment_method    VARCHAR2,
113           p_voucher_id    NUMBER,
114           p_voucher_number    VARCHAR2,
115           p_payment_reference_id    NUMBER,
116           p_payment_reference_number    VARCHAR2,
117           p_payment_reference_date    DATE,
118           p_payment_status    VARCHAR2,
119           p_approved_flag    VARCHAR2,
120           p_approved_date    DATE,
121           p_approved_by    NUMBER,
122           p_settled_date    DATE,
123           p_settled_by    NUMBER,
124           p_effective_date    DATE,
125           p_custom_setup_id    NUMBER,
126           p_task_id    NUMBER,
127           p_country_id    NUMBER,
128 	  p_order_type_id    NUMBER,
129           p_comments    VARCHAR2,
130           p_attribute_category    VARCHAR2,
131           p_attribute1    VARCHAR2,
132           p_attribute2    VARCHAR2,
133           p_attribute3    VARCHAR2,
134           p_attribute4    VARCHAR2,
135           p_attribute5    VARCHAR2,
136           p_attribute6    VARCHAR2,
137           p_attribute7    VARCHAR2,
138           p_attribute8    VARCHAR2,
139           p_attribute9    VARCHAR2,
140           p_attribute10    VARCHAR2,
141           p_attribute11    VARCHAR2,
142           p_attribute12    VARCHAR2,
143           p_attribute13    VARCHAR2,
144           p_attribute14    VARCHAR2,
145           p_attribute15    VARCHAR2,
146           p_deduction_attribute_category    VARCHAR2,
147           p_deduction_attribute1    VARCHAR2,
148           p_deduction_attribute2    VARCHAR2,
149           p_deduction_attribute3    VARCHAR2,
150           p_deduction_attribute4    VARCHAR2,
151           p_deduction_attribute5    VARCHAR2,
152           p_deduction_attribute6    VARCHAR2,
153           p_deduction_attribute7    VARCHAR2,
154           p_deduction_attribute8    VARCHAR2,
155           p_deduction_attribute9    VARCHAR2,
156           p_deduction_attribute10    VARCHAR2,
157           p_deduction_attribute11    VARCHAR2,
158           p_deduction_attribute12    VARCHAR2,
159           p_deduction_attribute13    VARCHAR2,
160           p_deduction_attribute14    VARCHAR2,
161           p_deduction_attribute15    VARCHAR2,
162           px_org_id   IN OUT NOCOPY NUMBER,
163           p_customer_reason           VARCHAR2,
164           p_ship_to_cust_account_id   NUMBER
165           )
166 
167  IS
168    x_rowid    VARCHAR2(30);
169 
170 
171 BEGIN
172 
173    IF (px_org_id IS NULL OR px_org_id = FND_API.G_MISS_NUM) THEN
174        SELECT NVL(SUBSTRB(USERENV('CLIENT_INFO'),1,10),-99)
175        INTO px_org_id
176        FROM DUAL;
177    END IF;
178 
179 
180    px_object_version_number := 1;
181 
182 
183    INSERT INTO OZF_CLAIMS_INT_ALL(
184            interface_claim_id,
185            object_version_number,
186            last_update_date,
187            last_updated_by,
188            creation_date,
189            created_by,
190            last_update_login,
191            request_id,
192            program_application_id,
193            program_update_date,
194            program_id,
195            created_from,
196            batch_id,
197            claim_id,
198            claim_number,
199            claim_type_id,
200            claim_class,
201            claim_date,
202            due_date,
203            owner_id,
204            history_event,
205            history_event_date,
206            history_event_description,
207            split_from_claim_id,
208            duplicate_claim_id,
209            split_date,
210            root_claim_id,
211            amount,
212            amount_adjusted,
213            amount_remaining,
214            amount_settled,
215            acctd_amount,
216            acctd_amount_remaining,
217            tax_amount,
218            tax_code,
219            tax_calculation_flag,
220            currency_code,
221            exchange_rate_type,
222            exchange_rate_date,
223            exchange_rate,
224            set_of_books_id,
225            original_claim_date,
226            source_object_id,
227            source_object_class,
228            source_object_type_id,
229            source_object_number,
230            cust_account_id,
231            cust_billto_acct_site_id,
232            cust_shipto_acct_site_id,
233            location_id,
234            pay_related_account_flag,
235            related_cust_account_id,
236            related_site_use_id,
237            relationship_type,
238            vendor_id,
239            vendor_site_id,
240            reason_type,
241            reason_code_id,
242            task_template_group_id,
243            status_code,
244            user_status_id,
245            sales_rep_id,
246            collector_id,
247            contact_id,
248            broker_id,
249            territory_id,
250            customer_ref_date,
251            customer_ref_number,
252            assigned_to,
253            receipt_id,
254            receipt_number,
255            doc_sequence_id,
256            doc_sequence_value,
257            gl_date,
258            payment_method,
259            voucher_id,
260            voucher_number,
261            payment_reference_id,
262            payment_reference_number,
263            payment_reference_date,
264            payment_status,
265            approved_flag,
266            approved_date,
267            approved_by,
268            settled_date,
269            settled_by,
270            effective_date,
271            custom_setup_id,
272            task_id,
273            country_id,
274 	   order_type_id,
275            comments,
276            attribute_category,
277            attribute1,
278            attribute2,
279            attribute3,
280            attribute4,
281            attribute5,
282            attribute6,
283            attribute7,
284            attribute8,
285            attribute9,
286            attribute10,
287            attribute11,
288            attribute12,
289            attribute13,
290            attribute14,
291            attribute15,
292            deduction_attribute_category,
293            deduction_attribute1,
294            deduction_attribute2,
295            deduction_attribute3,
296            deduction_attribute4,
297            deduction_attribute5,
298            deduction_attribute6,
299            deduction_attribute7,
300            deduction_attribute8,
301            deduction_attribute9,
302            deduction_attribute10,
303            deduction_attribute11,
304            deduction_attribute12,
305            deduction_attribute13,
306            deduction_attribute14,
307            deduction_attribute15,
308            org_id,
309            customer_reason,
310            ship_to_cust_account_id
311 
312    ) VALUES (
313            px_interface_claim_id,
314            px_object_version_number,
315            p_last_update_date,
316            p_last_updated_by,
317            p_creation_date,
318            p_created_by,
319            p_last_update_login,
320            p_request_id,
321            p_program_application_id,
322            p_program_update_date,
323            p_program_id,
324            p_created_from,
325            p_batch_id,
326            p_claim_id,
327            p_claim_number,
328            p_claim_type_id,
329            p_claim_class,
330            p_claim_date,
331            p_due_date,
332            p_owner_id,
333            p_history_event,
334            p_history_event_date,
335            p_history_event_description,
336            p_split_from_claim_id,
337            p_duplicate_claim_id,
338            p_split_date,
339            p_root_claim_id,
340            p_amount,
341            p_amount_adjusted,
342            p_amount_remaining,
343            p_amount_settled,
344            p_acctd_amount,
345            p_acctd_amount_remaining,
346            p_tax_amount,
347            p_tax_code,
348            p_tax_calculation_flag,
349            p_currency_code,
350            p_exchange_rate_type,
351            p_exchange_rate_date,
352            p_exchange_rate,
353            p_set_of_books_id,
354            p_original_claim_date,
355            p_source_object_id,
356            p_source_object_class,
357            p_source_object_type_id,
358            p_source_object_number,
359            p_cust_account_id,
360            p_cust_billto_acct_site_id,
361            p_cust_shipto_acct_site_id,
362            p_location_id,
363            p_pay_related_account_flag,
364            p_related_cust_account_id,
365            p_related_site_use_id,
366            p_relationship_type,
367            p_vendor_id,
368            p_vendor_site_id,
369            p_reason_type,
370            p_reason_code_id,
371            p_task_template_group_id,
372            p_status_code,
373            p_user_status_id,
374            p_sales_rep_id,
375            p_collector_id,
376            p_contact_id,
377            p_broker_id,
378            p_territory_id,
379            p_customer_ref_date,
380            p_customer_ref_number,
381            p_assigned_to,
382            p_receipt_id,
383            p_receipt_number,
384            p_doc_sequence_id,
385            p_doc_sequence_value,
386            p_gl_date,
387            p_payment_method,
388            p_voucher_id,
389            p_voucher_number,
390            p_payment_reference_id,
391            p_payment_reference_number,
392            p_payment_reference_date,
393            p_payment_status,
394            p_approved_flag,
395            p_approved_date,
396            p_approved_by,
397            p_settled_date,
398            p_settled_by,
399            p_effective_date,
400            p_custom_setup_id,
401            p_task_id,
402            p_country_id,
403 	   p_order_type_id,
404            p_comments,
405            p_attribute_category,
406            p_attribute1,
407            p_attribute2,
408            p_attribute3,
409            p_attribute4,
410            p_attribute5,
411            p_attribute6,
412            p_attribute7,
413            p_attribute8,
414            p_attribute9,
415            p_attribute10,
416            p_attribute11,
417            p_attribute12,
418            p_attribute13,
419            p_attribute14,
420            p_attribute15,
421            p_deduction_attribute_category,
425            p_deduction_attribute4,
422            p_deduction_attribute1,
423            p_deduction_attribute2,
424            p_deduction_attribute3,
426            p_deduction_attribute5,
427            p_deduction_attribute6,
428            p_deduction_attribute7,
429            p_deduction_attribute8,
430            p_deduction_attribute9,
431            p_deduction_attribute10,
432            p_deduction_attribute11,
433            p_deduction_attribute12,
434            p_deduction_attribute13,
435            p_deduction_attribute14,
436            p_deduction_attribute15,
437            px_org_id,
438            p_customer_reason,
439            p_ship_to_cust_account_id);
440 
441 END Insert_Row;
442 
443 
444 ----------------------------------------------------------
445 ----          MEDIA           ----
446 ----------------------------------------------------------
447 
448 --  ========================================================
449 --
450 --  NAME
451 --  createUpdateBody
452 --
453 --  PURPOSE
454 --
455 --  NOTES
456 --
457 --  HISTORY
458 --
459 --  ========================================================
460 PROCEDURE Update_Row(
461           p_interface_claim_id    NUMBER,
462           p_object_version_number    NUMBER,
463           p_last_update_date    DATE,
464           p_last_updated_by    NUMBER,
465           p_last_update_login    NUMBER,
466           p_request_id    NUMBER,
467           p_program_application_id    NUMBER,
468           p_program_update_date    DATE,
469           p_program_id    NUMBER,
470           p_created_from    VARCHAR2,
471           p_batch_id    NUMBER,
472           p_claim_id    NUMBER,
473           p_claim_number    VARCHAR2,
474           p_claim_type_id    NUMBER,
475           p_claim_class    VARCHAR2,
476           p_claim_date    DATE,
477           p_due_date    DATE,
478           p_owner_id    NUMBER,
479           p_history_event    VARCHAR2,
480           p_history_event_date    DATE,
481           p_history_event_description    VARCHAR2,
482           p_split_from_claim_id    NUMBER,
483           p_duplicate_claim_id    NUMBER,
484           p_split_date    DATE,
485           p_root_claim_id    NUMBER,
486           p_amount    NUMBER,
487           p_amount_adjusted    NUMBER,
488           p_amount_remaining    NUMBER,
489           p_amount_settled    NUMBER,
490           p_acctd_amount    NUMBER,
491           p_acctd_amount_remaining    NUMBER,
492           p_tax_amount    NUMBER,
493           p_tax_code    VARCHAR2,
494           p_tax_calculation_flag    VARCHAR2,
495           p_currency_code    VARCHAR2,
496           p_exchange_rate_type    VARCHAR2,
497           p_exchange_rate_date    DATE,
498           p_exchange_rate    NUMBER,
499           p_set_of_books_id    NUMBER,
500           p_original_claim_date    DATE,
501           p_source_object_id    NUMBER,
502           p_source_object_class    VARCHAR2,
503           p_source_object_type_id    NUMBER,
504           p_source_object_number    VARCHAR2,
505           p_cust_account_id    NUMBER,
506           p_cust_billto_acct_site_id    NUMBER,
507           p_cust_shipto_acct_site_id    NUMBER,
508           p_location_id    NUMBER,
509           p_pay_related_account_flag    VARCHAR2,
510           p_related_cust_account_id    NUMBER,
511           p_related_site_use_id    NUMBER,
512           p_relationship_type    VARCHAR2,
513           p_vendor_id    NUMBER,
514           p_vendor_site_id    NUMBER,
515           p_reason_type    VARCHAR2,
516           p_reason_code_id    NUMBER,
517           p_task_template_group_id    NUMBER,
518           p_status_code    VARCHAR2,
519           p_user_status_id    NUMBER,
520           p_sales_rep_id    NUMBER,
521           p_collector_id    NUMBER,
522           p_contact_id    NUMBER,
523           p_broker_id    NUMBER,
524           p_territory_id    NUMBER,
525           p_customer_ref_date    DATE,
526           p_customer_ref_number    VARCHAR2,
527           p_assigned_to    NUMBER,
528           p_receipt_id    NUMBER,
529           p_receipt_number    VARCHAR2,
530           p_doc_sequence_id    NUMBER,
531           p_doc_sequence_value    NUMBER,
532           p_gl_date    DATE,
533           p_payment_method    VARCHAR2,
534           p_voucher_id    NUMBER,
535           p_voucher_number    VARCHAR2,
536           p_payment_reference_id    NUMBER,
537           p_payment_reference_number    VARCHAR2,
538           p_payment_reference_date    DATE,
539           p_payment_status    VARCHAR2,
540           p_approved_flag    VARCHAR2,
541           p_approved_date    DATE,
542           p_approved_by    NUMBER,
543           p_settled_date    DATE,
544           p_settled_by    NUMBER,
545           p_effective_date    DATE,
546           p_custom_setup_id    NUMBER,
547           p_task_id    NUMBER,
548           p_country_id    NUMBER,
549 	  p_order_type_id NUMBER,
550           p_comments    VARCHAR2,
551           p_attribute_category    VARCHAR2,
552           p_attribute1    VARCHAR2,
553           p_attribute2    VARCHAR2,
554           p_attribute3    VARCHAR2,
555           p_attribute4    VARCHAR2,
556           p_attribute5    VARCHAR2,
557           p_attribute6    VARCHAR2,
558           p_attribute7    VARCHAR2,
559           p_attribute8    VARCHAR2,
563           p_attribute12    VARCHAR2,
560           p_attribute9    VARCHAR2,
561           p_attribute10    VARCHAR2,
562           p_attribute11    VARCHAR2,
564           p_attribute13    VARCHAR2,
565           p_attribute14    VARCHAR2,
566           p_attribute15    VARCHAR2,
567           p_deduction_attribute_category    VARCHAR2,
568           p_deduction_attribute1    VARCHAR2,
569           p_deduction_attribute2    VARCHAR2,
570           p_deduction_attribute3    VARCHAR2,
571           p_deduction_attribute4    VARCHAR2,
572           p_deduction_attribute5    VARCHAR2,
573           p_deduction_attribute6    VARCHAR2,
574           p_deduction_attribute7    VARCHAR2,
575           p_deduction_attribute8    VARCHAR2,
576           p_deduction_attribute9    VARCHAR2,
577           p_deduction_attribute10    VARCHAR2,
578           p_deduction_attribute11    VARCHAR2,
579           p_deduction_attribute12    VARCHAR2,
580           p_deduction_attribute13    VARCHAR2,
581           p_deduction_attribute14    VARCHAR2,
582           p_deduction_attribute15    VARCHAR2,
583           p_org_id    NUMBER,
584           p_customer_reason           VARCHAR2,
585           p_ship_to_cust_account_id   NUMBER)
586 
587  IS
588  BEGIN
589     Update OZF_CLAIMS_INT_ALL
590     SET
591               interface_claim_id = p_interface_claim_id,
592               object_version_number = p_object_version_number,
593               last_update_date = p_last_update_date,
594               last_updated_by = p_last_updated_by,
595               last_update_login = p_last_update_login,
596               request_id = p_request_id,
597               program_application_id = p_program_application_id,
598               program_update_date = p_program_update_date,
599               program_id = p_program_id,
600               created_from = p_created_from,
601               batch_id = p_batch_id,
602               claim_id = p_claim_id,
603               claim_number = p_claim_number,
604               claim_type_id = p_claim_type_id,
605               claim_class = p_claim_class,
606               claim_date = p_claim_date,
607               due_date = p_due_date,
608               owner_id = p_owner_id,
609               history_event = p_history_event,
610               history_event_date = p_history_event_date,
611               history_event_description = p_history_event_description,
612               split_from_claim_id = p_split_from_claim_id,
613               duplicate_claim_id = p_duplicate_claim_id,
614               split_date = p_split_date,
615               root_claim_id = p_root_claim_id,
616               amount = p_amount,
617               amount_adjusted = p_amount_adjusted,
618               amount_remaining = p_amount_remaining,
619               amount_settled = p_amount_settled,
620               acctd_amount = p_acctd_amount,
621               acctd_amount_remaining = p_acctd_amount_remaining,
622               tax_amount = p_tax_amount,
623               tax_code = p_tax_code,
624               tax_calculation_flag = p_tax_calculation_flag,
625               currency_code = p_currency_code,
626               exchange_rate_type = p_exchange_rate_type,
627               exchange_rate_date = p_exchange_rate_date,
628               exchange_rate = p_exchange_rate,
629               set_of_books_id = p_set_of_books_id,
630               original_claim_date = p_original_claim_date,
631               source_object_id = p_source_object_id,
632               source_object_class = p_source_object_class,
633               source_object_type_id = p_source_object_type_id,
634               source_object_number = p_source_object_number,
635               cust_account_id = p_cust_account_id,
636               cust_billto_acct_site_id = p_cust_billto_acct_site_id,
637               cust_shipto_acct_site_id = p_cust_shipto_acct_site_id,
638               location_id = p_location_id,
639               pay_related_account_flag = p_pay_related_account_flag,
640               related_cust_account_id = p_related_cust_account_id,
641               related_site_use_id = p_related_site_use_id,
642               relationship_type = p_relationship_type,
643               vendor_id = p_vendor_id,
644               vendor_site_id = p_vendor_site_id,
645               reason_type = p_reason_type,
646               reason_code_id = p_reason_code_id,
647               task_template_group_id = p_task_template_group_id,
648               status_code = p_status_code,
649               user_status_id = p_user_status_id,
650               sales_rep_id = p_sales_rep_id,
651               collector_id = p_collector_id,
652               contact_id = p_contact_id,
653               broker_id = p_broker_id,
654               territory_id = p_territory_id,
655               customer_ref_date = p_customer_ref_date,
656               customer_ref_number = p_customer_ref_number,
657               assigned_to = p_assigned_to,
658               receipt_id = p_receipt_id,
659               receipt_number = p_receipt_number,
660               doc_sequence_id = p_doc_sequence_id,
661               doc_sequence_value = p_doc_sequence_value,
662               gl_date = p_gl_date,
663               payment_method = p_payment_method,
664               voucher_id = p_voucher_id,
665               voucher_number = p_voucher_number,
666               payment_reference_id = p_payment_reference_id,
667               payment_reference_number = p_payment_reference_number,
668               payment_reference_date = p_payment_reference_date,
669               payment_status = p_payment_status,
670               approved_flag = p_approved_flag,
671               approved_date = p_approved_date,
675               effective_date = p_effective_date,
672               approved_by = p_approved_by,
673               settled_date = p_settled_date,
674               settled_by = p_settled_by,
676               custom_setup_id = p_custom_setup_id,
677               task_id = p_task_id,
678               country_id = p_country_id,
679               order_type_id = p_order_type_id,
680 	      comments = p_comments,
681               attribute_category = p_attribute_category,
682               attribute1 = p_attribute1,
683               attribute2 = p_attribute2,
684               attribute3 = p_attribute3,
685               attribute4 = p_attribute4,
686               attribute5 = p_attribute5,
687               attribute6 = p_attribute6,
688               attribute7 = p_attribute7,
689               attribute8 = p_attribute8,
690               attribute9 = p_attribute9,
691               attribute10 = p_attribute10,
692               attribute11 = p_attribute11,
693               attribute12 = p_attribute12,
694               attribute13 = p_attribute13,
695               attribute14 = p_attribute14,
696               attribute15 = p_attribute15,
697               deduction_attribute_category = p_deduction_attribute_category,
698               deduction_attribute1 = p_deduction_attribute1,
699               deduction_attribute2 = p_deduction_attribute2,
700               deduction_attribute3 = p_deduction_attribute3,
701               deduction_attribute4 = p_deduction_attribute4,
702               deduction_attribute5 = p_deduction_attribute5,
703               deduction_attribute6 = p_deduction_attribute6,
704               deduction_attribute7 = p_deduction_attribute7,
705               deduction_attribute8 = p_deduction_attribute8,
706               deduction_attribute9 = p_deduction_attribute9,
707               deduction_attribute10 = p_deduction_attribute10,
708               deduction_attribute11 = p_deduction_attribute11,
709               deduction_attribute12 = p_deduction_attribute12,
710               deduction_attribute13 = p_deduction_attribute13,
711               deduction_attribute14 = p_deduction_attribute14,
712               deduction_attribute15 = p_deduction_attribute15,
713               org_id = p_org_id,
714               customer_reason = p_customer_reason,
715               ship_to_cust_account_id = p_ship_to_cust_account_id
716    WHERE INTERFACE_CLAIM_ID = p_INTERFACE_CLAIM_ID
717    AND   object_version_number = p_object_version_number;
718 
719    IF (SQL%NOTFOUND) THEN
720 RAISE  FND_API.G_EXC_UNEXPECTED_ERROR;
721    END IF;
722 END Update_Row;
723 
724 
725 ----------------------------------------------------------
726 ----          MEDIA           ----
727 ----------------------------------------------------------
728 
729 --  ========================================================
730 --
731 --  NAME
732 --  createDeleteBody
733 --
734 --  PURPOSE
735 --
736 --  NOTES
737 --
738 --  HISTORY
739 --
740 --  ========================================================
741 PROCEDURE Delete_Row(
742     p_INTERFACE_CLAIM_ID  NUMBER)
743  IS
744  BEGIN
745    DELETE FROM OZF_CLAIMS_INT_ALL
746     WHERE INTERFACE_CLAIM_ID = p_INTERFACE_CLAIM_ID;
747    If (SQL%NOTFOUND) then
748 RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
749    End If;
750  END Delete_Row ;
751 
752 
753 
754 ----------------------------------------------------------
755 ----          MEDIA           ----
756 ----------------------------------------------------------
757 
758 --  ========================================================
759 --
760 --  NAME
761 --  createLockBody
762 --
763 --  PURPOSE
764 --
765 --  NOTES
766 --
767 --  HISTORY
768 --
769 --  ========================================================
770 PROCEDURE Lock_Row(
771           p_interface_claim_id    NUMBER,
772           p_object_version_number    NUMBER,
773           p_last_update_date    DATE,
774           p_last_updated_by    NUMBER,
775           p_creation_date    DATE,
776           p_created_by    NUMBER,
777           p_last_update_login    NUMBER,
778           p_request_id    NUMBER,
779           p_program_application_id    NUMBER,
780           p_program_update_date    DATE,
781           p_program_id    NUMBER,
782           p_created_from    VARCHAR2,
783           p_batch_id    NUMBER,
784           p_claim_id    NUMBER,
785           p_claim_number    VARCHAR2,
786           p_claim_type_id    NUMBER,
787           p_claim_class    VARCHAR2,
788           p_claim_date    DATE,
789           p_due_date    DATE,
790           p_owner_id    NUMBER,
791           p_history_event    VARCHAR2,
792           p_history_event_date    DATE,
793           p_history_event_description    VARCHAR2,
794           p_split_from_claim_id    NUMBER,
795           p_duplicate_claim_id    NUMBER,
796           p_split_date    DATE,
797           p_root_claim_id    NUMBER,
798           p_amount    NUMBER,
799           p_amount_adjusted    NUMBER,
800           p_amount_remaining    NUMBER,
801           p_amount_settled    NUMBER,
802           p_acctd_amount    NUMBER,
803           p_acctd_amount_remaining    NUMBER,
804           p_tax_amount    NUMBER,
805           p_tax_code    VARCHAR2,
806           p_tax_calculation_flag    VARCHAR2,
807           p_currency_code    VARCHAR2,
811           p_set_of_books_id    NUMBER,
808           p_exchange_rate_type    VARCHAR2,
809           p_exchange_rate_date    DATE,
810           p_exchange_rate    NUMBER,
812           p_original_claim_date    DATE,
813           p_source_object_id    NUMBER,
814           p_source_object_class    VARCHAR2,
815           p_source_object_type_id    NUMBER,
816           p_source_object_number    VARCHAR2,
817           p_cust_account_id    NUMBER,
818           p_cust_billto_acct_site_id    NUMBER,
819           p_cust_shipto_acct_site_id    NUMBER,
820           p_location_id    NUMBER,
821           p_pay_related_account_flag    VARCHAR2,
822           p_related_cust_account_id    NUMBER,
823           p_related_site_use_id    NUMBER,
824           p_relationship_type    VARCHAR2,
825           p_vendor_id    NUMBER,
826           p_vendor_site_id    NUMBER,
827           p_reason_type    VARCHAR2,
828           p_reason_code_id    NUMBER,
829           p_task_template_group_id    NUMBER,
830           p_status_code    VARCHAR2,
831           p_user_status_id    NUMBER,
832           p_sales_rep_id    NUMBER,
833           p_collector_id    NUMBER,
834           p_contact_id    NUMBER,
835           p_broker_id    NUMBER,
836           p_territory_id    NUMBER,
837           p_customer_ref_date    DATE,
838           p_customer_ref_number    VARCHAR2,
839           p_assigned_to    NUMBER,
840           p_receipt_id    NUMBER,
841           p_receipt_number    VARCHAR2,
842           p_doc_sequence_id    NUMBER,
843           p_doc_sequence_value    NUMBER,
844           p_gl_date    DATE,
845           p_payment_method    VARCHAR2,
846           p_voucher_id    NUMBER,
847           p_voucher_number    VARCHAR2,
848           p_payment_reference_id    NUMBER,
849           p_payment_reference_number    VARCHAR2,
850           p_payment_reference_date    DATE,
851           p_payment_status    VARCHAR2,
852           p_approved_flag    VARCHAR2,
853           p_approved_date    DATE,
854           p_approved_by    NUMBER,
855           p_settled_date    DATE,
856           p_settled_by    NUMBER,
857           p_effective_date    DATE,
858           p_custom_setup_id    NUMBER,
859           p_task_id    NUMBER,
860           p_country_id    NUMBER,
861 	  p_order_type_id NUMBER,
862           p_comments    VARCHAR2,
863           p_attribute_category    VARCHAR2,
864           p_attribute1    VARCHAR2,
865           p_attribute2    VARCHAR2,
866           p_attribute3    VARCHAR2,
867           p_attribute4    VARCHAR2,
868           p_attribute5    VARCHAR2,
869           p_attribute6    VARCHAR2,
870           p_attribute7    VARCHAR2,
871           p_attribute8    VARCHAR2,
872           p_attribute9    VARCHAR2,
873           p_attribute10    VARCHAR2,
874           p_attribute11    VARCHAR2,
875           p_attribute12    VARCHAR2,
876           p_attribute13    VARCHAR2,
877           p_attribute14    VARCHAR2,
878           p_attribute15    VARCHAR2,
879           p_deduction_attribute_category    VARCHAR2,
880           p_deduction_attribute1    VARCHAR2,
881           p_deduction_attribute2    VARCHAR2,
882           p_deduction_attribute3    VARCHAR2,
883           p_deduction_attribute4    VARCHAR2,
884           p_deduction_attribute5    VARCHAR2,
885           p_deduction_attribute6    VARCHAR2,
886           p_deduction_attribute7    VARCHAR2,
887           p_deduction_attribute8    VARCHAR2,
888           p_deduction_attribute9    VARCHAR2,
889           p_deduction_attribute10    VARCHAR2,
890           p_deduction_attribute11    VARCHAR2,
891           p_deduction_attribute12    VARCHAR2,
892           p_deduction_attribute13    VARCHAR2,
893           p_deduction_attribute14    VARCHAR2,
894           p_deduction_attribute15    VARCHAR2,
895           p_org_id    NUMBER,
896           p_customer_reason           VARCHAR2,
897           p_ship_to_cust_account_id   NUMBER)
898 
899  IS
900    CURSOR C IS
901         SELECT *
902          FROM OZF_CLAIMS_INT_ALL
903         WHERE INTERFACE_CLAIM_ID =  p_INTERFACE_CLAIM_ID
904         FOR UPDATE of INTERFACE_CLAIM_ID NOWAIT;
905    Recinfo C%ROWTYPE;
906  BEGIN
907     OPEN c;
908     FETCH c INTO Recinfo;
909     If (c%NOTFOUND) then
910         CLOSE c;
911         FND_MESSAGE.SET_NAME('OZF', 'OZF_API_RECORD_NOT_FOUND');
912         APP_EXCEPTION.RAISE_EXCEPTION;
913     END IF;
914     CLOSE C;
915     IF (
916            (      Recinfo.interface_claim_id = p_interface_claim_id)
917        AND (    ( Recinfo.object_version_number = p_object_version_number)
918             OR (    ( Recinfo.object_version_number IS NULL )
919                 AND (  p_object_version_number IS NULL )))
920        AND (    ( Recinfo.last_update_date = p_last_update_date)
921             OR (    ( Recinfo.last_update_date IS NULL )
922                 AND (  p_last_update_date IS NULL )))
923        AND (    ( Recinfo.last_updated_by = p_last_updated_by)
924             OR (    ( Recinfo.last_updated_by IS NULL )
925                 AND (  p_last_updated_by IS NULL )))
926        AND (    ( Recinfo.creation_date = p_creation_date)
927             OR (    ( Recinfo.creation_date IS NULL )
928                 AND (  p_creation_date IS NULL )))
929        AND (    ( Recinfo.created_by = p_created_by)
930             OR (    ( Recinfo.created_by IS NULL )
931                 AND (  p_created_by IS NULL )))
935        AND (    ( Recinfo.request_id = p_request_id)
932        AND (    ( Recinfo.last_update_login = p_last_update_login)
933             OR (    ( Recinfo.last_update_login IS NULL )
934                 AND (  p_last_update_login IS NULL )))
936             OR (    ( Recinfo.request_id IS NULL )
937                 AND (  p_request_id IS NULL )))
938        AND (    ( Recinfo.program_application_id = p_program_application_id)
939             OR (    ( Recinfo.program_application_id IS NULL )
940                 AND (  p_program_application_id IS NULL )))
941        AND (    ( Recinfo.program_update_date = p_program_update_date)
942             OR (    ( Recinfo.program_update_date IS NULL )
943                 AND (  p_program_update_date IS NULL )))
944        AND (    ( Recinfo.program_id = p_program_id)
945             OR (    ( Recinfo.program_id IS NULL )
946                 AND (  p_program_id IS NULL )))
947        AND (    ( Recinfo.created_from = p_created_from)
948             OR (    ( Recinfo.created_from IS NULL )
949                 AND (  p_created_from IS NULL )))
950        AND (    ( Recinfo.batch_id = p_batch_id)
951             OR (    ( Recinfo.batch_id IS NULL )
952                 AND (  p_batch_id IS NULL )))
953        AND (    ( Recinfo.claim_id = p_claim_id)
954             OR (    ( Recinfo.claim_id IS NULL )
955                 AND (  p_claim_id IS NULL )))
956        AND (    ( Recinfo.claim_number = p_claim_number)
957             OR (    ( Recinfo.claim_number IS NULL )
958                 AND (  p_claim_number IS NULL )))
959        AND (    ( Recinfo.claim_type_id = p_claim_type_id)
960             OR (    ( Recinfo.claim_type_id IS NULL )
961                 AND (  p_claim_type_id IS NULL )))
962        AND (    ( Recinfo.claim_class = p_claim_class)
963             OR (    ( Recinfo.claim_class IS NULL )
964                 AND (  p_claim_class IS NULL )))
965        AND (    ( Recinfo.claim_date = p_claim_date)
966             OR (    ( Recinfo.claim_date IS NULL )
967                 AND (  p_claim_date IS NULL )))
968        AND (    ( Recinfo.due_date = p_due_date)
969             OR (    ( Recinfo.due_date IS NULL )
970                 AND (  p_due_date IS NULL )))
971        AND (    ( Recinfo.owner_id = p_owner_id)
972             OR (    ( Recinfo.owner_id IS NULL )
973                 AND (  p_owner_id IS NULL )))
974        AND (    ( Recinfo.history_event = p_history_event)
975             OR (    ( Recinfo.history_event IS NULL )
976                 AND (  p_history_event IS NULL )))
977        AND (    ( Recinfo.history_event_date = p_history_event_date)
978             OR (    ( Recinfo.history_event_date IS NULL )
979                 AND (  p_history_event_date IS NULL )))
980        AND (    ( Recinfo.history_event_description = p_history_event_description)
981             OR (    ( Recinfo.history_event_description IS NULL )
982                 AND (  p_history_event_description IS NULL )))
983        AND (    ( Recinfo.split_from_claim_id = p_split_from_claim_id)
984             OR (    ( Recinfo.split_from_claim_id IS NULL )
985                 AND (  p_split_from_claim_id IS NULL )))
986        AND (    ( Recinfo.duplicate_claim_id = p_duplicate_claim_id)
987             OR (    ( Recinfo.duplicate_claim_id IS NULL )
988                 AND (  p_duplicate_claim_id IS NULL )))
989        AND (    ( Recinfo.split_date = p_split_date)
990             OR (    ( Recinfo.split_date IS NULL )
991                 AND (  p_split_date IS NULL )))
992        AND (    ( Recinfo.root_claim_id = p_root_claim_id)
993             OR (    ( Recinfo.root_claim_id IS NULL )
994                 AND (  p_root_claim_id IS NULL )))
995        AND (    ( Recinfo.amount = p_amount)
996             OR (    ( Recinfo.amount IS NULL )
997                 AND (  p_amount IS NULL )))
998        AND (    ( Recinfo.amount_adjusted = p_amount_adjusted)
999             OR (    ( Recinfo.amount_adjusted IS NULL )
1000                 AND (  p_amount_adjusted IS NULL )))
1001        AND (    ( Recinfo.amount_remaining = p_amount_remaining)
1002             OR (    ( Recinfo.amount_remaining IS NULL )
1003                 AND (  p_amount_remaining IS NULL )))
1004        AND (    ( Recinfo.amount_settled = p_amount_settled)
1005             OR (    ( Recinfo.amount_settled IS NULL )
1006                 AND (  p_amount_settled IS NULL )))
1007        AND (    ( Recinfo.acctd_amount = p_acctd_amount)
1008             OR (    ( Recinfo.acctd_amount IS NULL )
1009                 AND (  p_acctd_amount IS NULL )))
1010        AND (    ( Recinfo.acctd_amount_remaining = p_acctd_amount_remaining)
1011             OR (    ( Recinfo.acctd_amount_remaining IS NULL )
1012                 AND (  p_acctd_amount_remaining IS NULL )))
1013        AND (    ( Recinfo.tax_amount = p_tax_amount)
1014             OR (    ( Recinfo.tax_amount IS NULL )
1015                 AND (  p_tax_amount IS NULL )))
1016        AND (    ( Recinfo.tax_code = p_tax_code)
1017             OR (    ( Recinfo.tax_code IS NULL )
1018                 AND (  p_tax_code IS NULL )))
1019        AND (    ( Recinfo.tax_calculation_flag = p_tax_calculation_flag)
1020             OR (    ( Recinfo.tax_calculation_flag IS NULL )
1021                 AND (  p_tax_calculation_flag IS NULL )))
1022        AND (    ( Recinfo.currency_code = p_currency_code)
1023             OR (    ( Recinfo.currency_code IS NULL )
1024                 AND (  p_currency_code IS NULL )))
1025        AND (    ( Recinfo.exchange_rate_type = p_exchange_rate_type)
1026             OR (    ( Recinfo.exchange_rate_type IS NULL )
1027                 AND (  p_exchange_rate_type IS NULL )))
1028        AND (    ( Recinfo.exchange_rate_date = p_exchange_rate_date)
1029             OR (    ( Recinfo.exchange_rate_date IS NULL )
1030                 AND (  p_exchange_rate_date IS NULL )))
1031        AND (    ( Recinfo.exchange_rate = p_exchange_rate)
1032             OR (    ( Recinfo.exchange_rate IS NULL )
1033                 AND (  p_exchange_rate IS NULL )))
1034        AND (    ( Recinfo.set_of_books_id = p_set_of_books_id)
1035             OR (    ( Recinfo.set_of_books_id IS NULL )
1036                 AND (  p_set_of_books_id IS NULL )))
1037        AND (    ( Recinfo.original_claim_date = p_original_claim_date)
1038             OR (    ( Recinfo.original_claim_date IS NULL )
1039                 AND (  p_original_claim_date IS NULL )))
1040        AND (    ( Recinfo.source_object_id = p_source_object_id)
1041             OR (    ( Recinfo.source_object_id IS NULL )
1042                 AND (  p_source_object_id IS NULL )))
1043        AND (    ( Recinfo.source_object_class = p_source_object_class)
1044             OR (    ( Recinfo.source_object_class IS NULL )
1045                 AND (  p_source_object_class IS NULL )))
1046        AND (    ( Recinfo.source_object_type_id = p_source_object_type_id)
1047             OR (    ( Recinfo.source_object_type_id IS NULL )
1048                 AND (  p_source_object_type_id IS NULL )))
1049        AND (    ( Recinfo.source_object_number = p_source_object_number)
1050             OR (    ( Recinfo.source_object_number IS NULL )
1051                 AND (  p_source_object_number IS NULL )))
1052        AND (    ( Recinfo.cust_account_id = p_cust_account_id)
1053             OR (    ( Recinfo.cust_account_id IS NULL )
1054                 AND (  p_cust_account_id IS NULL )))
1055        AND (    ( Recinfo.cust_billto_acct_site_id = p_cust_billto_acct_site_id)
1056             OR (    ( Recinfo.cust_billto_acct_site_id IS NULL )
1057                 AND (  p_cust_billto_acct_site_id IS NULL )))
1058        AND (    ( Recinfo.cust_shipto_acct_site_id = p_cust_shipto_acct_site_id)
1059             OR (    ( Recinfo.cust_shipto_acct_site_id IS NULL )
1060                 AND (  p_cust_shipto_acct_site_id IS NULL )))
1061        AND (    ( Recinfo.location_id = p_location_id)
1062             OR (    ( Recinfo.location_id IS NULL )
1063                 AND (  p_location_id IS NULL )))
1067        AND (    ( Recinfo.related_cust_account_id = p_related_cust_account_id)
1064        AND (    ( Recinfo.pay_related_account_flag = p_pay_related_account_flag)
1065             OR (    ( Recinfo.pay_related_account_flag IS NULL )
1066                 AND (  p_pay_related_account_flag IS NULL )))
1068             OR (    ( Recinfo.related_cust_account_id IS NULL )
1069                 AND (  p_related_cust_account_id IS NULL )))
1070        AND (    ( Recinfo.related_site_use_id = p_related_site_use_id)
1071             OR (    ( Recinfo.related_site_use_id IS NULL )
1072                 AND (  p_related_site_use_id IS NULL )))
1073        AND (    ( Recinfo.relationship_type = p_relationship_type)
1074             OR (    ( Recinfo.relationship_type IS NULL )
1075                 AND (  p_relationship_type IS NULL )))
1076        AND (    ( Recinfo.vendor_id = p_vendor_id)
1077             OR (    ( Recinfo.vendor_id IS NULL )
1078                 AND (  p_vendor_id IS NULL )))
1079        AND (    ( Recinfo.vendor_site_id = p_vendor_site_id)
1080             OR (    ( Recinfo.vendor_site_id IS NULL )
1081                 AND (  p_vendor_site_id IS NULL )))
1082        AND (    ( Recinfo.reason_type = p_reason_type)
1083             OR (    ( Recinfo.reason_type IS NULL )
1084                 AND (  p_reason_type IS NULL )))
1085        AND (    ( Recinfo.reason_code_id = p_reason_code_id)
1086             OR (    ( Recinfo.reason_code_id IS NULL )
1087                 AND (  p_reason_code_id IS NULL )))
1088        AND (    ( Recinfo.task_template_group_id = p_task_template_group_id)
1089             OR (    ( Recinfo.task_template_group_id IS NULL )
1090                 AND (  p_task_template_group_id IS NULL )))
1091        AND (    ( Recinfo.status_code = p_status_code)
1092             OR (    ( Recinfo.status_code IS NULL )
1093                 AND (  p_status_code IS NULL )))
1094        AND (    ( Recinfo.user_status_id = p_user_status_id)
1095             OR (    ( Recinfo.user_status_id IS NULL )
1096                 AND (  p_user_status_id IS NULL )))
1097        AND (    ( Recinfo.sales_rep_id = p_sales_rep_id)
1098             OR (    ( Recinfo.sales_rep_id IS NULL )
1099                 AND (  p_sales_rep_id IS NULL )))
1100        AND (    ( Recinfo.collector_id = p_collector_id)
1101             OR (    ( Recinfo.collector_id IS NULL )
1102                 AND (  p_collector_id IS NULL )))
1103        AND (    ( Recinfo.contact_id = p_contact_id)
1104             OR (    ( Recinfo.contact_id IS NULL )
1105                 AND (  p_contact_id IS NULL )))
1106        AND (    ( Recinfo.broker_id = p_broker_id)
1107             OR (    ( Recinfo.broker_id IS NULL )
1108                 AND (  p_broker_id IS NULL )))
1109        AND (    ( Recinfo.territory_id = p_territory_id)
1110             OR (    ( Recinfo.territory_id IS NULL )
1111                 AND (  p_territory_id IS NULL )))
1112        AND (    ( Recinfo.customer_ref_date = p_customer_ref_date)
1113             OR (    ( Recinfo.customer_ref_date IS NULL )
1114                 AND (  p_customer_ref_date IS NULL )))
1115        AND (    ( Recinfo.customer_ref_number = p_customer_ref_number)
1116             OR (    ( Recinfo.customer_ref_number IS NULL )
1117                 AND (  p_customer_ref_number IS NULL )))
1118        AND (    ( Recinfo.assigned_to = p_assigned_to)
1119             OR (    ( Recinfo.assigned_to IS NULL )
1120                 AND (  p_assigned_to IS NULL )))
1121        AND (    ( Recinfo.receipt_id = p_receipt_id)
1122             OR (    ( Recinfo.receipt_id IS NULL )
1123                 AND (  p_receipt_id IS NULL )))
1124        AND (    ( Recinfo.receipt_number = p_receipt_number)
1125             OR (    ( Recinfo.receipt_number IS NULL )
1126                 AND (  p_receipt_number IS NULL )))
1127        AND (    ( Recinfo.doc_sequence_id = p_doc_sequence_id)
1128             OR (    ( Recinfo.doc_sequence_id IS NULL )
1129                 AND (  p_doc_sequence_id IS NULL )))
1130        AND (    ( Recinfo.doc_sequence_value = p_doc_sequence_value)
1131             OR (    ( Recinfo.doc_sequence_value IS NULL )
1132                 AND (  p_doc_sequence_value IS NULL )))
1133        AND (    ( Recinfo.gl_date = p_gl_date)
1134             OR (    ( Recinfo.gl_date IS NULL )
1135                 AND (  p_gl_date IS NULL )))
1136        AND (    ( Recinfo.payment_method = p_payment_method)
1137             OR (    ( Recinfo.payment_method IS NULL )
1138                 AND (  p_payment_method IS NULL )))
1139        AND (    ( Recinfo.voucher_id = p_voucher_id)
1140             OR (    ( Recinfo.voucher_id IS NULL )
1141                 AND (  p_voucher_id IS NULL )))
1142        AND (    ( Recinfo.voucher_number = p_voucher_number)
1143             OR (    ( Recinfo.voucher_number IS NULL )
1144                 AND (  p_voucher_number IS NULL )))
1145        AND (    ( Recinfo.payment_reference_id = p_payment_reference_id)
1146             OR (    ( Recinfo.payment_reference_id IS NULL )
1147                 AND (  p_payment_reference_id IS NULL )))
1148        AND (    ( Recinfo.payment_reference_number = p_payment_reference_number)
1152             OR (    ( Recinfo.payment_reference_date IS NULL )
1149             OR (    ( Recinfo.payment_reference_number IS NULL )
1150                 AND (  p_payment_reference_number IS NULL )))
1151        AND (    ( Recinfo.payment_reference_date = p_payment_reference_date)
1153                 AND (  p_payment_reference_date IS NULL )))
1154        AND (    ( Recinfo.payment_status = p_payment_status)
1155             OR (    ( Recinfo.payment_status IS NULL )
1156                 AND (  p_payment_status IS NULL )))
1157        AND (    ( Recinfo.approved_flag = p_approved_flag)
1158             OR (    ( Recinfo.approved_flag IS NULL )
1159                 AND (  p_approved_flag IS NULL )))
1160        AND (    ( Recinfo.approved_date = p_approved_date)
1161             OR (    ( Recinfo.approved_date IS NULL )
1162                 AND (  p_approved_date IS NULL )))
1163        AND (    ( Recinfo.approved_by = p_approved_by)
1164             OR (    ( Recinfo.approved_by IS NULL )
1165                 AND (  p_approved_by IS NULL )))
1166        AND (    ( Recinfo.settled_date = p_settled_date)
1167             OR (    ( Recinfo.settled_date IS NULL )
1168                 AND (  p_settled_date IS NULL )))
1169        AND (    ( Recinfo.settled_by = p_settled_by)
1170             OR (    ( Recinfo.settled_by IS NULL )
1171                 AND (  p_settled_by IS NULL )))
1172        AND (    ( Recinfo.effective_date = p_effective_date)
1173             OR (    ( Recinfo.effective_date IS NULL )
1174                 AND (  p_effective_date IS NULL )))
1175        AND (    ( Recinfo.custom_setup_id = p_custom_setup_id)
1176             OR (    ( Recinfo.custom_setup_id IS NULL )
1177                 AND (  p_custom_setup_id IS NULL )))
1178        AND (    ( Recinfo.task_id = p_task_id)
1179             OR (    ( Recinfo.task_id IS NULL )
1180                 AND (  p_task_id IS NULL )))
1181        AND (    ( Recinfo.country_id = p_country_id)
1182             OR (    ( Recinfo.country_id IS NULL )
1183                 AND (  p_country_id IS NULL )))
1184        AND (    ( Recinfo.order_type_id = p_order_type_id)
1185             OR (    ( Recinfo.order_type_id IS NULL )
1186                 AND (  p_order_type_id IS NULL )))
1187        AND (    ( Recinfo.comments = p_comments)
1188             OR (    ( Recinfo.comments IS NULL )
1189                 AND (  p_comments IS NULL )))
1190        AND (    ( Recinfo.attribute_category = p_attribute_category)
1191             OR (    ( Recinfo.attribute_category IS NULL )
1192                 AND (  p_attribute_category IS NULL )))
1193        AND (    ( Recinfo.attribute1 = p_attribute1)
1194             OR (    ( Recinfo.attribute1 IS NULL )
1195                 AND (  p_attribute1 IS NULL )))
1196        AND (    ( Recinfo.attribute2 = p_attribute2)
1197             OR (    ( Recinfo.attribute2 IS NULL )
1198                 AND (  p_attribute2 IS NULL )))
1199        AND (    ( Recinfo.attribute3 = p_attribute3)
1200             OR (    ( Recinfo.attribute3 IS NULL )
1201                 AND (  p_attribute3 IS NULL )))
1202        AND (    ( Recinfo.attribute4 = p_attribute4)
1203             OR (    ( Recinfo.attribute4 IS NULL )
1204                 AND (  p_attribute4 IS NULL )))
1205        AND (    ( Recinfo.attribute5 = p_attribute5)
1206             OR (    ( Recinfo.attribute5 IS NULL )
1207                 AND (  p_attribute5 IS NULL )))
1208        AND (    ( Recinfo.attribute6 = p_attribute6)
1209             OR (    ( Recinfo.attribute6 IS NULL )
1210                 AND (  p_attribute6 IS NULL )))
1211        AND (    ( Recinfo.attribute7 = p_attribute7)
1212             OR (    ( Recinfo.attribute7 IS NULL )
1213                 AND (  p_attribute7 IS NULL )))
1214        AND (    ( Recinfo.attribute8 = p_attribute8)
1215             OR (    ( Recinfo.attribute8 IS NULL )
1216                 AND (  p_attribute8 IS NULL )))
1217        AND (    ( Recinfo.attribute9 = p_attribute9)
1218             OR (    ( Recinfo.attribute9 IS NULL )
1219                 AND (  p_attribute9 IS NULL )))
1220        AND (    ( Recinfo.attribute10 = p_attribute10)
1221             OR (    ( Recinfo.attribute10 IS NULL )
1222                 AND (  p_attribute10 IS NULL )))
1223        AND (    ( Recinfo.attribute11 = p_attribute11)
1224             OR (    ( Recinfo.attribute11 IS NULL )
1225                 AND (  p_attribute11 IS NULL )))
1226        AND (    ( Recinfo.attribute12 = p_attribute12)
1227             OR (    ( Recinfo.attribute12 IS NULL )
1228                 AND (  p_attribute12 IS NULL )))
1229        AND (    ( Recinfo.attribute13 = p_attribute13)
1230             OR (    ( Recinfo.attribute13 IS NULL )
1231                 AND (  p_attribute13 IS NULL )))
1232        AND (    ( Recinfo.attribute14 = p_attribute14)
1233             OR (    ( Recinfo.attribute14 IS NULL )
1234                 AND (  p_attribute14 IS NULL )))
1235        AND (    ( Recinfo.attribute15 = p_attribute15)
1236             OR (    ( Recinfo.attribute15 IS NULL )
1237                 AND (  p_attribute15 IS NULL )))
1238        AND (    ( Recinfo.deduction_attribute_category = p_deduction_attribute_category)
1239             OR (    ( Recinfo.deduction_attribute_category IS NULL )
1240                 AND (  p_deduction_attribute_category IS NULL )))
1241        AND (    ( Recinfo.deduction_attribute1 = p_deduction_attribute1)
1242             OR (    ( Recinfo.deduction_attribute1 IS NULL )
1250        AND (    ( Recinfo.deduction_attribute4 = p_deduction_attribute4)
1243                 AND (  p_deduction_attribute1 IS NULL )))
1244        AND (    ( Recinfo.deduction_attribute2 = p_deduction_attribute2)
1245             OR (    ( Recinfo.deduction_attribute2 IS NULL )
1246                 AND (  p_deduction_attribute2 IS NULL )))
1247        AND (    ( Recinfo.deduction_attribute3 = p_deduction_attribute3)
1248             OR (    ( Recinfo.deduction_attribute3 IS NULL )
1249                 AND (  p_deduction_attribute3 IS NULL )))
1251             OR (    ( Recinfo.deduction_attribute4 IS NULL )
1252                 AND (  p_deduction_attribute4 IS NULL )))
1253        AND (    ( Recinfo.deduction_attribute5 = p_deduction_attribute5)
1254             OR (    ( Recinfo.deduction_attribute5 IS NULL )
1255                 AND (  p_deduction_attribute5 IS NULL )))
1256        AND (    ( Recinfo.deduction_attribute6 = p_deduction_attribute6)
1257             OR (    ( Recinfo.deduction_attribute6 IS NULL )
1258                 AND (  p_deduction_attribute6 IS NULL )))
1259        AND (    ( Recinfo.deduction_attribute7 = p_deduction_attribute7)
1260             OR (    ( Recinfo.deduction_attribute7 IS NULL )
1261                 AND (  p_deduction_attribute7 IS NULL )))
1262        AND (    ( Recinfo.deduction_attribute8 = p_deduction_attribute8)
1263             OR (    ( Recinfo.deduction_attribute8 IS NULL )
1264                 AND (  p_deduction_attribute8 IS NULL )))
1265        AND (    ( Recinfo.deduction_attribute9 = p_deduction_attribute9)
1266             OR (    ( Recinfo.deduction_attribute9 IS NULL )
1267                 AND (  p_deduction_attribute9 IS NULL )))
1268        AND (    ( Recinfo.deduction_attribute10 = p_deduction_attribute10)
1269             OR (    ( Recinfo.deduction_attribute10 IS NULL )
1270                 AND (  p_deduction_attribute10 IS NULL )))
1271        AND (    ( Recinfo.deduction_attribute11 = p_deduction_attribute11)
1272             OR (    ( Recinfo.deduction_attribute11 IS NULL )
1273                 AND (  p_deduction_attribute11 IS NULL )))
1274        AND (    ( Recinfo.deduction_attribute12 = p_deduction_attribute12)
1275             OR (    ( Recinfo.deduction_attribute12 IS NULL )
1276                 AND (  p_deduction_attribute12 IS NULL )))
1277        AND (    ( Recinfo.deduction_attribute13 = p_deduction_attribute13)
1278             OR (    ( Recinfo.deduction_attribute13 IS NULL )
1279                 AND (  p_deduction_attribute13 IS NULL )))
1280        AND (    ( Recinfo.deduction_attribute14 = p_deduction_attribute14)
1281             OR (    ( Recinfo.deduction_attribute14 IS NULL )
1282                 AND (  p_deduction_attribute14 IS NULL )))
1283        AND (    ( Recinfo.deduction_attribute15 = p_deduction_attribute15)
1284             OR (    ( Recinfo.deduction_attribute15 IS NULL )
1285                 AND (  p_deduction_attribute15 IS NULL )))
1286        AND (    ( Recinfo.org_id = p_org_id)
1287             OR (    ( Recinfo.org_id IS NULL )
1288                 AND (  p_org_id IS NULL )))
1289        AND (    ( Recinfo.customer_reason = p_customer_reason)
1290             OR (    ( Recinfo.customer_reason IS NULL )
1291                 AND (  p_customer_reason IS NULL )))
1292        AND (    ( Recinfo.ship_to_cust_account_id = p_ship_to_cust_account_id)
1293             OR (    ( Recinfo.ship_to_cust_account_id IS NULL )
1294                 AND (  p_ship_to_cust_account_id IS NULL )))
1295        ) THEN
1296        RETURN;
1297    ELSE
1298        FND_MESSAGE.SET_NAME('OZF', 'OZF_API_RECORD_NOT_FOUND');
1299        APP_EXCEPTION.RAISE_EXCEPTION;
1300    END IF;
1301 END Lock_Row;
1302 
1303 END OZF_CLAIMS_INT_PKG;