DBA Data[Home] [Help]

APPS.QP_PS_ATTR_GRP_PVT dependencies on QP_PATTERN_PHASES

Line 232: FROM qp_pattern_phases

228: active_flag
229: INTO l_old_start_date,
230: l_old_end_date,
231: l_old_active_flag
232: FROM qp_pattern_phases
233: WHERE pricing_phase_id = l_phase_ids_tbl(i)
234: AND pattern_id = l_pattern_ids_tbl(i);
235:
236: IF ((l_old_start_date IS NULL) OR

Line 257: UPDATE qp_pattern_phases

253: l_active_flag_tbl(i) := l_old_active_flag;
254: END IF;
255:
256:
257: UPDATE qp_pattern_phases
258: SET start_date_active = l_start_date_tbl(i),
259: end_date_active = l_end_date_tbl(i),
260: active_flag = l_active_flag_tbl(i)
261: WHERE pricing_phase_id = l_phase_ids_tbl(i)

Line 311: UPDATE qp_pattern_phases

307:
308: END IF; -- IF 3
309:
310: FORALL i IN 1..l_phase_ids_tbl.COUNT
311: UPDATE qp_pattern_phases
312: SET start_date_active = l_start_date_tbl(i),
313: end_date_active = l_end_date_tbl(i),
314: active_flag = l_active_flag_tbl(i)
315: WHERE pricing_phase_id = l_phase_ids_tbl(i)

Line 349: UPDATE qp_pattern_phases

345:
346: END IF; -- IF 4
347:
348: FORALL i IN 1..l_phase_ids_tbl.COUNT
349: UPDATE qp_pattern_phases
350: SET start_date_active = l_start_date_tbl(i)
351: WHERE pricing_phase_id = l_phase_ids_tbl(i)
352: AND pattern_id = l_pattern_ids_tbl(i)
353: AND ((l_start_date_tbl(i) IS NULL )

Line 360: UPDATE qp_pattern_phases

356: start_date_active > l_start_date_tbl(i)
357: ));
358:
359: FORALL i IN 1..l_phase_ids_tbl.COUNT
360: UPDATE qp_pattern_phases
361: SET end_date_active = l_end_date_tbl(i)
362: WHERE pricing_phase_id = l_phase_ids_tbl(i)
363: AND pattern_id = l_pattern_ids_tbl(i)
364: AND ((l_end_date_tbl(i) IS NULL )

Line 371: UPDATE qp_pattern_phases

367: end_date_active < l_end_date_tbl(i)
368: ));
369:
370: FORALL i IN 1..l_phase_ids_tbl.COUNT
371: UPDATE qp_pattern_phases
372: SET active_flag = NVL(l_active_flag_tbl(i),'N')
373: WHERE pricing_phase_id = l_phase_ids_tbl(i)
374: AND pattern_id = l_pattern_ids_tbl(i)
375: AND NVL(active_flag,'N') <> 'Y';

Line 605: delete from qp_pattern_phases a

601: where pattern_id = g_pattern_pattern_id_final_tbl(i);
602: end if;
603:
604: -- delete the records where pricing_phase_id matches to avoid duplicates
605: delete from qp_pattern_phases a
606: where a.pattern_id = g_pattern_pattern_id_final_tbl(i)
607: and a.pricing_phase_id in (select b.pricing_phase_id
608: from qp_pattern_phases b
609: where b.pattern_id = l_min_pattern_id);

Line 608: from qp_pattern_phases b

604: -- delete the records where pricing_phase_id matches to avoid duplicates
605: delete from qp_pattern_phases a
606: where a.pattern_id = g_pattern_pattern_id_final_tbl(i)
607: and a.pricing_phase_id in (select b.pricing_phase_id
608: from qp_pattern_phases b
609: where b.pattern_id = l_min_pattern_id);
610:
611: -- update the records where pricing_phase_id DO NOT matches
612: update qp_pattern_phases

Line 612: update qp_pattern_phases

608: from qp_pattern_phases b
609: where b.pattern_id = l_min_pattern_id);
610:
611: -- update the records where pricing_phase_id DO NOT matches
612: update qp_pattern_phases
613: set pattern_id = l_min_pattern_id
614: where pattern_id = g_pattern_pattern_id_final_tbl(i);
615: end loop;
616: end if;

Line 627: update qp_pattern_phases a

623: g_pattern_pat_type_final_tbl.delete;
624: g_pattern_pat_string_final_tbl.delete;
625:
626: ----Added for PL/SQL Pattern Search
627: update qp_pattern_phases a
628: set (start_date_active, end_date_active, active_flag) =
629: (
630: select decode(min(nvl(sda,g_min_date)),g_min_date,null,min(sda)) min_start_date,
631: decode(max(nvl(eda,g_max_date)),g_max_date,null,max(eda)) max_end_date,

Line 866: /*DELETE qp_pattern_phases

862: END IF;
863: ----Added for PL/SQL Pattern Search
864:
865: -- bug 12731268
866: /*DELETE qp_pattern_phases
867: where pattern_id IN (-2,-3)
868: AND pricing_phase_id=1;*/
869:
870: select hsecs into l_end_time from v$timer;

Line 884: l_stmt := 'TRUNCATE TABLE ' || l_qp_schema || '.qp_pattern_phases';

880: -- like upgrade, refresh everything related to patterns
881: IF (FND_INSTALLATION.GET_APP_INFO('QP', l_status, l_industry, l_qp_schema))
882: THEN
883:
884: l_stmt := 'TRUNCATE TABLE ' || l_qp_schema || '.qp_pattern_phases';
885: EXECUTE IMMEDIATE l_stmt;
886: l_stmt := 'TRUNCATE TABLE ' || l_qp_schema || '.qp_attribute_groups';
887: EXECUTE IMMEDIATE l_stmt;
888: l_stmt := 'TRUNCATE TABLE ' || l_qp_schema || '.qp_patterns';

Line 3227: -- maintain data in qp_pattern_phases

3223: write_log( 'Pattern_id='||l_pattern_id);
3224: end if;
3225: */
3226:
3227: -- maintain data in qp_pattern_phases
3228: if p_pattern_type in ('LP', 'PP') then
3229: Populate_Pattern_Phases(null, g_pricing_phase_id_tmp_tbl(grp_no_index), l_pattern_id);
3230: elsif p_pattern_type = 'HP' THEN
3231: Populate_Pattern_Phases(g_list_header_id_tmp_tbl(grp_no_index), null, l_pattern_id);

Line 4114: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'

4110: */
4111: FOR j IN l_phase_id_to_insert_csr LOOP
4112: l_prl_flag := 'Y';
4113: begin
4114: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'
4115: into l_exists
4116: from qp_pattern_phases qp_pp
4117: where pattern_id = p_pattern_id
4118: and pricing_phase_id = j.pricing_phase_id;

Line 4116: from qp_pattern_phases qp_pp

4112: l_prl_flag := 'Y';
4113: begin
4114: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'
4115: into l_exists
4116: from qp_pattern_phases qp_pp
4117: where pattern_id = p_pattern_id
4118: and pricing_phase_id = j.pricing_phase_id;
4119: exception
4120: when no_data_found then

Line 4121: INSERT INTO qp_pattern_phases

4117: where pattern_id = p_pattern_id
4118: and pricing_phase_id = j.pricing_phase_id;
4119: exception
4120: when no_data_found then
4121: INSERT INTO qp_pattern_phases
4122: (pattern_id,
4123: pricing_phase_id,
4124: creation_date,
4125: created_by,

Line 4165: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'

4161: where list_header_id = p_list_header_id;
4162:
4163: if l_list_type = 'PRL' then
4164: begin
4165: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'
4166: into l_exists
4167: from qp_pattern_phases qp_pp
4168: where pattern_id = p_pattern_id
4169: and pricing_phase_id = 1;

Line 4167: from qp_pattern_phases qp_pp

4163: if l_list_type = 'PRL' then
4164: begin
4165: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'
4166: into l_exists
4167: from qp_pattern_phases qp_pp
4168: where pattern_id = p_pattern_id
4169: and pricing_phase_id = 1;
4170: exception
4171: when no_data_found then

Line 4172: INSERT INTO qp_pattern_phases

4168: where pattern_id = p_pattern_id
4169: and pricing_phase_id = 1;
4170: exception
4171: when no_data_found then
4172: INSERT INTO qp_pattern_phases
4173: (pattern_id,
4174: pricing_phase_id,
4175: creation_date,
4176: created_by,

Line 4217: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'

4213: write_log( 'Begin Populate_Pattern_Phases for LP, PP case');
4214: end if;
4215: */
4216: begin
4217: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'
4218: into l_exists
4219: from qp_pattern_phases qp_pp
4220: where pattern_id = p_pattern_id
4221: and pricing_phase_id = p_pricing_phase_id

Line 4219: from qp_pattern_phases qp_pp

4215: */
4216: begin
4217: select /*+ index(qp_pp QP_PATTERN_PHASES_N1) */ 'Y'
4218: into l_exists
4219: from qp_pattern_phases qp_pp
4220: where pattern_id = p_pattern_id
4221: and pricing_phase_id = p_pricing_phase_id
4222: and rownum = 1; -- needed in case same combination is inserted by 2 diff. threads and one has commited before other
4223: exception

Line 4232: INSERT INTO qp_pattern_phases

4228: else
4229: write_log( 'No pattern_phases found; go insert');
4230: end if;
4231: */
4232: INSERT INTO qp_pattern_phases
4233: (pattern_id,
4234: pricing_phase_id,
4235: creation_date,
4236: created_by,