[Home] [Help]
161:
162: /* Commenting code below for Bug 6312921 */
163: -- cursor c0 is
164: -- select 1
165: -- from pa_ind_compiled_sets ics
166: -- where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
167: -- and exists (select null
168: -- from pa_expenditure_items ei
169: -- where tp_ind_compiled_set_id = ics.ind_compiled_set_id);
168: -- from pa_expenditure_items ei
169: -- where tp_ind_compiled_set_id = ics.ind_compiled_set_id);
170: -- cursor c1 is
171: -- select 1
172: -- from pa_ind_compiled_sets ics
173: -- where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
174: -- /*and not exists (select null -- Changed the not exists to exists */
175: -- and exists (select /*+ index(ei PA_EXPENDITURE_ITEMS_N11) */ null --added hint for bug 5845101
176: -- from pa_expenditure_items ei
177: -- where cost_ind_compiled_set_id = ics.ind_compiled_set_id);
178: --
179: -- cursor c2 is
180: -- select 1
181: -- from pa_ind_compiled_sets ics
182: -- where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
183: -- /*and not exists (select null -- Changed the not exists to exists */
184: -- and exists (select null
185: -- from pa_expenditure_items
186: -- where rev_ind_compiled_set_id = ics.ind_compiled_set_id);
187: --
188: -- cursor c3 is
189: -- select 1
190: -- from pa_ind_compiled_sets ics
191: --where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
192: -- /*and not exists (select null -- Changed the not exists to exists */
193: -- and exists (select null
194: -- from pa_expenditure_items
197: /* Commenting code for Bug 6312921 ends here */
198: /* Code added for Bug 6312921 :- starts */
199: Cursor cind is
200: select ics.ind_compiled_set_id
201: from pa_ind_compiled_sets ics
202: where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id ;
203:
204: cursor c0 (l_ind_compile_set_id number) is
205: select 1
247: /*Start ---- Added this cursor for 5877935 */
248: /* Code commented for Bug 6312921 - */
249: /*cursor c4 is
250: select 1 from dual where exists (
251: select 1 from pa_ind_compiled_sets ICS
252: WHERE ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id and
253: (exists
254: (SELECT NULL FROM pa_cost_distribution_lines_all CDL
255: WHERE ICS.ind_compiled_set_id = CDL.ind_compiled_set_id
304: from sys.dual
305: where not exists
306: (select 1
307: from pa_expenditure_items ei,
308: pa_ind_compiled_sets ics
309: where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
310: and ( (ei.cost_ind_compiled_set_id = ics.ind_compiled_set_id)
311: or (ei.rev_ind_compiled_set_id = ics.ind_compiled_set_id)
312: or (ei.inv_ind_compiled_set_id = ics.ind_compiled_set_id)));
468:
469:
470: cursor c0 is
471: select 1
472: from pa_ind_compiled_sets ics
473: where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
474: and exists (select null
475: from pa_expenditure_items ei
476: where tp_ind_compiled_set_id = ics.ind_compiled_set_id and expenditure_item_date > x_end_date_active);
477:
478:
479: cursor c1 is
480: select 1
481: from pa_ind_compiled_sets ics
482: where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
483: /*and not exists (select null -- Changed the not exists to exists */
484: and exists (select null
485: from pa_expenditure_items_all ei
486: where cost_ind_compiled_set_id = ics.ind_compiled_set_id and expenditure_item_date > x_end_date_active);
487:
488: cursor c2 is
489: select 1
490: from pa_ind_compiled_sets ics
491: where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
492: /*and not exists (select null -- Changed the not exists to exists */
493: and exists (select null
494: from pa_expenditure_items_all
495: where rev_ind_compiled_set_id = ics.ind_compiled_set_id and expenditure_item_date > x_end_date_active);
496:
497: cursor c3 is
498: select 1
499: from pa_ind_compiled_sets ics
500: where ics.ind_rate_sch_revision_id = x_ind_rate_sch_revision_id
501: /*and not exists (select null -- Changed the not exists to exists */
502: and exists (select null
503: from pa_expenditure_items_all
504: where inv_ind_compiled_set_id = ics.ind_compiled_set_id and expenditure_item_date > x_end_date_active);
505:
506: /* Bug6081362 */
507: cursor c4 is
508: select 1 from dual where exists (select 1 from pa_ind_compiled_sets ICS
509: WHERE ics.ind_rate_sch_revision_id =x_ind_rate_sch_revision_id and
510: exists (SELECT NULL FROM gms_encumbrance_items_all gei
511: WHERE ICS.ind_compiled_set_id = gei.ind_compiled_set_id
512: and ENCUMBRANCE_ITEM_DATE > x_end_date_active