43: select 1
44: into net_exists
45: from dual
46: where exists (select null
47: from bom_operation_networks_v
48: where routing_sequence_id = p_rtg_sequence_id
49: and operation_type = 3);
50:
51: return (TRUE);
273: I Integer := 1;
274: /*Cursor all_line_ops is
275: select from_seq_num operation_seq_num ,
276: from_op_seq_id operation_sequence_id
277: from bom_operation_networks_v
278: where routing_sequence_id = l_rtg_seq_id
279: and operation_type = 3
280: and transition_type <> 3
281: union
280: and transition_type <> 3
281: union
282: select bonv.to_seq_num operation_seq_num,
283: to_op_seq_id operation_sequence_id
284: from bom_operation_networks_v bonv
285: where routing_sequence_id = l_rtg_seq_id
286: and operation_type = 3
287: and not exists (select null
288: from bom_operation_networks_v net
284: from bom_operation_networks_v bonv
285: where routing_sequence_id = l_rtg_seq_id
286: and operation_type = 3
287: and not exists (select null
288: from bom_operation_networks_v net
289: where bonv.to_op_seq_id = net.from_op_seq_id
290: and transition_type <> 3
291: and net.routing_sequence_id = l_rtg_seq_id);
292: */
358: I Integer := 1;
359: /*Cursor all_primary_line_ops is
360: select from_seq_num operation_seq_num ,
361: from_op_seq_id operation_sequence_id
362: from bom_operation_networks_v
363: where routing_sequence_id = l_rtg_seq_id
364: and transition_type = 1
365: and operation_type = 3
366: union
365: and operation_type = 3
366: union
367: select bonv.to_seq_num operation_seq_num,
368: to_op_seq_id operation_sequence_id
369: from bom_operation_networks_v bonv
370: where routing_sequence_id = l_rtg_seq_id
371: and transition_type = 1
372: and operation_type = 3
373: and not exists (select null
370: where routing_sequence_id = l_rtg_seq_id
371: and transition_type = 1
372: and operation_type = 3
373: and not exists (select null
374: from bom_operation_networks_v net
375: where bonv.to_op_seq_id = net.from_op_seq_id
376: and transition_type <> 3
377: and net.routing_sequence_id = l_rtg_seq_id);
378: */
532: if check_network_exists(l_rtg_seq_id) then
533: BEGIN
534: select to_seq_num
535: into next_line_op
536: from bom_operation_networks_v
537: where routing_sequence_id = l_rtg_seq_id
538: and operation_type = 3
539: and from_seq_num = p_curr_line_op
540: and transition_type = 1;
544: EXCEPTION WHEN NO_DATA_FOUND THEN
545: BEGIN
546: select min(to_seq_num)
547: into next_line_op
548: from bom_operation_networks_v
549: where routing_sequence_id = l_rtg_seq_id
550: and operation_type = 3
551: and from_seq_num = p_curr_line_op
552: and transition_type = 2;
606: select 1
607: into l_last_op
608: from dual
609: where not exists (select null
610: from bom_operation_networks_v
611: where from_seq_num = p_curr_line_op
612: and operation_type = 3
613: and transition_type <> 3
614: and routing_sequence_id = l_rtg_seq_id)
612: and operation_type = 3
613: and transition_type <> 3
614: and routing_sequence_id = l_rtg_seq_id)
615: and exists (select null
616: from bom_operation_networks_v
617: where to_seq_num = p_curr_line_op
618: and transition_type <> 3
619: and operation_type = 3
620: and routing_sequence_id = l_rtg_seq_id);