324: select count(*) into v_counter
325: from mtl_reservations
326: --where demand_source_type_id = 2
327: where demand_source_type_id =
328: decode (l_source_document_type_id, 10, inv_reservation_global.g_source_type_internal_ord,
329: inv_reservation_global.g_source_type_oe ) -- bugfix 1799874
330: and demand_source_line_id = order_line_id
331: and primary_reservation_quantity > 0;
332:
325: from mtl_reservations
326: --where demand_source_type_id = 2
327: where demand_source_type_id =
328: decode (l_source_document_type_id, 10, inv_reservation_global.g_source_type_internal_ord,
329: inv_reservation_global.g_source_type_oe ) -- bugfix 1799874
330: and demand_source_line_id = order_line_id
331: and primary_reservation_quantity > 0;
332:
333: -- bugfix 1799874 : as per adrian suherman, we need not worry about internal SO for wip_flow_schedules.
611: select count(*) into v_counter
612: from mtl_reservations
613: -- where demand_source_type_id = 2
614: where demand_source_type_id =
615: decode (l_source_document_type_id, 10, inv_reservation_global.g_source_type_internal_ord,
616: inv_reservation_global.g_source_type_oe ) -- bugfix 1799874
617: and demand_source_line_id = order_line_id
618: and primary_reservation_quantity > 0;
619:
612: from mtl_reservations
613: -- where demand_source_type_id = 2
614: where demand_source_type_id =
615: decode (l_source_document_type_id, 10, inv_reservation_global.g_source_type_internal_ord,
616: inv_reservation_global.g_source_type_oe ) -- bugfix 1799874
617: and demand_source_line_id = order_line_id
618: and primary_reservation_quantity > 0;
619:
620: -- bugfix 1799874 : as per adrian suherman, we need not worry about internal SO for wip_flow_schedules.