1250: exception
1251: when NO_DATA_FOUND then
1252: select department_id, effectivity_date
1253: into dept_id, dummy_eff
1254: from bom_operation_sequences
1255: where operation_sequence_id = c1rec.OSI;
1256: when others then
1257: err_text := 'BOMPVALR(bmvres) ' || substrb(SQLERRM,1,60);
1258: return(SQLCODE);
2605: */
2606: begin
2607: select 1
2608: into cnt
2609: from bom_operation_sequences
2610: where operation_sequence_id = op_seq_id;
2611: if (exist_flag = 1) then
2612: return(0);
2613: else
2692: BEGIN
2693: begin
2694: select operation_sequence_id
2695: into cnt
2696: from bom_operation_sequences
2697: where routing_sequence_id = rtg_seq_id
2698: and to_char(effectivity_date,'YYYY/MM/DD HH24:MI:SS') = eff_date -- Changed for bug 2647027
2699: -- and to_char(effectivity_date,'YYYY/MM/DD HH24:MI') = eff_date
2700: and operation_seq_num = op_seq;
2775: ** first check in production tables
2776: */
2777: select count(*)
2778: into cnt
2779: from bom_operation_sequences
2780: where routing_sequence_id = rtg_id
2781: and operation_seq_num = op_num
2782: and ((dis_date is null
2783: and to_date(eff_date,'YYYY/MM/DD HH24:MI') <