940:
941: begin
942: select count(*)
943: into l_count
944: from wip_requirement_operations_v
945: where organization_id = p_organization_id
946: and wip_entity_id = p_wip_entity_id
947: and operation_seq_num = 1;
948:
960: wip_entity_id = p_wip_entity_id
961: and operation_seq_num = l_min_op_seq_num;
962: end if;
963:
964: update wip_requirement_operations
965: set operation_seq_num = l_min_op_seq_num,
966: department_id = l_department_id
967: where operation_seq_num = 1 and
968: organization_id = p_organization_id and