DBA Data[Home] [Help]

APPS.OE_DELAYED_REQUESTS_UTIL dependencies on OE_ORDER_LINES

Line 186: FROM OE_ORDER_LINES_ALL

182: SELECT Line_id, item_type_code,line_set_id,
183: Service_reference_line_id,
184: inventory_item_id,
185: service_reference_type_code --Bug 4946843
186: FROM OE_ORDER_LINES_ALL
187: WHERE Line_id = l_line_id;
188:
189: CURSOR MODEL_SERVICES IS
190: SELECT /* MOAC_SQL_CHANGE */ line_id, header_id

Line 191: FROM OE_ORDER_LINES

187: WHERE Line_id = l_line_id;
188:
189: CURSOR MODEL_SERVICES IS
190: SELECT /* MOAC_SQL_CHANGE */ line_id, header_id
191: FROM OE_ORDER_LINES
192: WHERE service_reference_line_id
193: in (SELECT line_id
194: FROM oe_order_lines_all
195: WHERE top_model_line_id = l_line_id1)

Line 194: FROM oe_order_lines_all

190: SELECT /* MOAC_SQL_CHANGE */ line_id, header_id
191: FROM OE_ORDER_LINES
192: WHERE service_reference_line_id
193: in (SELECT line_id
194: FROM oe_order_lines_all
195: WHERE top_model_line_id = l_line_id1)
196: AND line_id <> l_line_id and
197: inventory_item_id = l_temp_inv_item_id;
198:

Line 835: oe_order_lines o

831:
832: CURSOR all_adjustments IS
833: SELECT p.price_adjustment_id, Nvl(p.line_id, -1) line_id
834: FROM oe_price_adjustments p,
835: oe_order_lines o
836: WHERE p.header_id = l_header_id
837: AND o.header_id = l_header_id
838: AND (p.line_id = o.line_id
839: OR p.line_id IS NULL)

Line 860: FROM OE_PRICE_ADJUSTMENTS P, OE_ORDER_LINES L

856:
857:
858: CURSOR max_line_adj_total IS
859: SELECT NVL( MAX(SUM(PERCENT)), 0) + l_percent_total
860: FROM OE_PRICE_ADJUSTMENTS P, OE_ORDER_LINES L
861: WHERE P.HEADER_ID = l_header_id
862: AND P.LINE_ID IS NOT NULL
863: AND P.LINE_ID = L.LINE_ID
864: GROUP BY P.line_id;

Line 1267: FROM oe_order_lines

1263: SELECT header_id, reference_header_id, reference_line_id,split_by
1264: ,SOURCE_DOCUMENT_TYPE_ID --added source document id as a part of 6778016
1265: INTO l_header_id,l_ref_header_id, l_ref_line_id, l_split_by
1266: ,l_src_doc_type_id --added l_src_doc_type_id as a part of 6778016
1267: FROM oe_order_lines
1268: WHERE line_id = p_line_id;
1269: EXCEPTION
1270: WHEN NO_DATA_FOUND THEN
1271: OE_DEBUG_PUB.ADD('Invalid line_id',1);

Line 1318: FROM oe_order_lines

1314: /* moved to the beginning of the procedure to fix bug 3317323
1315: BEGIN
1316: SELECT header_id, reference_header_id, reference_line_id
1317: INTO l_header_id,l_ref_header_id, l_ref_line_id
1318: FROM oe_order_lines
1319: WHERE line_id = p_line_id;
1320: EXCEPTION
1321: WHEN NO_DATA_FOUND THEN
1322: OE_DEBUG_PUB.ADD('Invalid line_id',1);

Line 1916: FROM oe_order_lines

1912: OE_debug_pub.add('Line ID: '|| l_request_rec.entity_id,1);
1913: BEGIN
1914: SELECT header_id
1915: INTO l_header_id
1916: FROM oe_order_lines
1917: WHERE line_id = l_request_rec.entity_id;
1918: OE_debug_pub.add('OEXUREQB:Header ID: '|| l_header_id);
1919:
1920:

Line 2080: FROM oe_order_lines

2076: OE_debug_pub.add('Line ID: '|| l_request_rec.entity_id,1);
2077: BEGIN
2078: SELECT header_id
2079: INTO l_header_id
2080: FROM oe_order_lines
2081: WHERE line_id = l_request_rec.entity_id;
2082: OE_debug_pub.add('OEXUREQB:Header ID: '|| l_header_id);
2083:
2084:

Line 2389: FROM oe_order_lines_all

2385:
2386: BEGIN
2387: SELECT header_id
2388: INTO l_header_id
2389: FROM oe_order_lines_all
2390: WHERE line_id = p_entity_id;
2391: EXCEPTION
2392: WHEN OTHERS THEN
2393: RAISE;

Line 2472: FROM oe_order_lines_all

2468:
2469: BEGIN
2470: SELECT header_id
2471: INTO l_header_id
2472: FROM oe_order_lines_all
2473: WHERE line_id = p_entity_id;
2474: EXCEPTION
2475: WHEN OTHERS THEN
2476: RAISE;

Line 2544: FROM oe_order_lines_all

2540: l_global_index NUMBER;
2541: CURSOR l_servbill_lin (
2542: p_header_id IN NUMBER) IS
2543: SELECT line_id
2544: FROM oe_order_lines_all
2545: WHERE header_id = p_header_id
2546: AND service_bill_option_code = 'FPOM'
2547: AND service_bill_profile_id IS NOT NULL
2548: AND service_start_date is NOT NULL --16621149

Line 2622: UPDATE oe_order_lines_all

2618: oe_debug_pub.ADD( ' Start Date,End Date are NULL, so Update FirstPeriod Amt and EndDate to NULL');
2619: End If;
2620: End If;
2621: --16621149 end
2622: UPDATE oe_order_lines_all
2623: SET service_first_period_amount = l_first_period_amt,
2624: service_first_period_enddate = l_first_period_enddate
2625: WHERE line_id = p_line_id;
2626: l_old_line_tbl(1) := l_line_rec;

Line 2697: UPDATE oe_order_lines_all

2693: oe_debug_pub.ADD( ' (2) After OKS Get Billed Amount, first_period_amt= '||l_first_period_amt
2694: ||' first_period_enddate= '||l_first_period_enddate);
2695: End If;
2696: -- Update the current line being processed
2697: UPDATE oe_order_lines_all
2698: SET service_first_period_amount = l_first_period_amt,
2699: service_first_period_enddate = l_first_period_enddate
2700: WHERE line_id = l_rec.line_id;
2701: l_old_line_tbl(1) := l_line_rec;

Line 2986: from oe_order_lines

2982: -- for valid as well as complete .
2983:
2984: select booked_flag
2985: into l_complete_flag
2986: from oe_order_lines
2987: where line_id = p_top_model_line_id;
2988:
2989: l_complete_flag := nvl(l_complete_flag, 'N');
2990: oe_debug_pub.add('option added to a booked order? : '||l_complete_flag , 2);

Line 3224: FROM oe_order_lines l,mtl_system_items m

3220:
3221: -- l_component_code VARCHAR2(2000);
3222: CURSOR rma_children IS
3223: SELECT l.header_id, l.line_id, l.ordered_quantity
3224: FROM oe_order_lines l,mtl_system_items m
3225: WHERE l.top_model_line_id = l_top_model_line_id
3226: AND nvl(l.ato_line_id,1) = nvl(l_ato_line_id,nvl(l.ato_line_id,1))
3227: AND l.link_to_line_id = nvl(l_link_to_line_id,l.link_to_line_id)
3228: AND line_id <> l_reference_line_id

Line 4275: -- FROM oe_order_lines l

4271: -- l.service_start_date,
4272: -- l.service_end_date,
4273: -- l.service_coterminate_flag,
4274: -- l.ordered_quantity
4275: -- FROM oe_order_lines l
4276: -- WHERE l.top_model_line_id = l_service_reference_line_id
4277: -- AND l.item_type_code in ('INCLUDED','CLASS','OPTION')
4278: -- AND exists (select null from mtl_system_items mtl where
4279: -- mtl.inventory_item_id = l.inventory_item_id and

Line 4286: FROM oe_order_lines l

4282: --lchen added check for organizations to fix bug 2039304
4283:
4284: CURSOR srv_number IS
4285: SELECT max(l.service_number) service_number
4286: FROM oe_order_lines l
4287: WHERE l.header_id = l_header_id
4288: AND l.line_number = l_line_number
4289: AND l.shipment_number = l_shipment_number
4290: AND nvl(l.option_number,0) = nvl(l_option_number,0)

Line 4312: FROM oe_order_headers_all h, oe_order_lines l

4308: x_line_rec => l_orig_line_rec);
4309:
4310: SELECT /* MOAC_SQL_CHANGE */ h.order_number
4311: INTO l_order_number
4312: FROM oe_order_headers_all h, oe_order_lines l
4313: WHERE h.header_id = l.header_id
4314: AND h.header_id = l_orig_line_rec.header_id
4315: AND rownum = 1;
4316:

Line 4388: FROM oe_order_lines l

4384: l.service_start_date,
4385: l.service_end_date,
4386: l.service_coterminate_flag,
4387: l.ordered_quantity
4388: FROM oe_order_lines l
4389: WHERE l.top_model_line_id = l_service_reference_line_id
4390: AND l.item_type_code = 'INCLUDED'
4391: AND exists (select null from mtl_system_items mtl where
4392: mtl.inventory_item_id = l.inventory_item_id and

Line 4412: FROM oe_order_lines l

4408: l.service_start_date,
4409: l.service_end_date,
4410: l.service_coterminate_flag,
4411: l.ordered_quantity
4412: FROM oe_order_lines l
4413: WHERE l.top_model_line_id = l_service_reference_line_id
4414: AND l.top_model_line_id <> l.line_id -- For bug 2938790
4415: AND l.item_type_code in ('INCLUDED','CLASS','OPTION', 'KIT') -- For bug 2447402
4416: AND exists (select null from mtl_system_items mtl where

Line 4663: FROM oe_order_lines l

4659: l.service_coterminate_flag,
4660: l.order_quantity_uom,
4661: l.inventory_item_id,
4662: l.subscription_enable_flag
4663: FROM oe_order_lines l
4664: where l.service_reference_line_id=l_top_model_line_id
4665: and l.item_type_code = 'SERVICE'
4666: and l.service_reference_type_code = 'ORDER';
4667:

Line 4670: FROM oe_order_lines l

4666: and l.service_reference_type_code = 'ORDER';
4667:
4668: CURSOR srv_number IS
4669: SELECT max(l.service_number) service_number
4670: FROM oe_order_lines l
4671: WHERE l.header_id = l_header_id
4672: AND l.line_number = l_line_number
4673: AND l.shipment_number = l_shipment_number
4674: AND nvl(l.option_number,0) = nvl(l_option_number,0)

Line 4694: FROM oe_order_headers_all h, oe_order_lines l

4690: x_line_rec => l_orig_line_rec);
4691:
4692: SELECT /* MOAC_SQL_CHANGE */ h.order_number
4693: INTO l_order_number
4694: FROM oe_order_headers_all h, oe_order_lines l
4695: WHERE h.header_id = l.header_id
4696: AND h.header_id = l_orig_line_rec.header_id
4697: AND rownum = 1;
4698:

Line 5063: FROM oe_order_lines_all

5059: -- schedule the whole ATO model.
5060: BEGIN
5061: SELECT ship_set_id,arrival_set_id
5062: INTO l_ship_set_id,l_arrival_set_id
5063: FROM oe_order_lines_all
5064: WHERE line_id = l_line_rec.ato_line_id;
5065: EXCEPTION
5066: WHEN OTHERS THEN
5067: l_ship_set_id := null;

Line 5260: UPDATE OE_ORDER_LINES_ALL

5256:
5257: IF p_sch_set_tbl(I).request_type = OE_GLOBALS.G_SCHEDULE_LINE
5258: THEN
5259:
5260: UPDATE OE_ORDER_LINES_ALL
5261: SET
5262: (SCHEDULE_SHIP_DATE,
5263: SCHEDULE_ARRIVAL_DATE,
5264: SHIP_FROM_ORG_ID,

Line 5272: FROM OE_ORDER_LINES_ALL

5268: null,
5269: decode(re_source_flag,'Y',ship_from_org_id,null),
5270: null,
5271: null
5272: FROM OE_ORDER_LINES_ALL
5273: WHERE line_id=l_line_rec.line_id)
5274: WHERE line_id = l_line_rec.line_id;
5275:
5276: ELSE

Line 5277: UPDATE OE_ORDER_LINES_ALL

5273: WHERE line_id=l_line_rec.line_id)
5274: WHERE line_id = l_line_rec.line_id;
5275:
5276: ELSE
5277: UPDATE OE_ORDER_LINES_ALL
5278: SET
5279: SCHEDULE_SHIP_DATE = l_old_line_rec.schedule_ship_date,
5280: SCHEDULE_ARRIVAL_DATE = l_old_line_rec.schedule_arrival_date,
5281: SHIP_FROM_ORG_ID = l_old_line_rec.ship_from_org_id,

Line 5451: /* getting total tax value from oe_order_lines_all table for line id*/

5447: END IF;
5448: l_total_tax:= l_total_tax + l_tax_rec_out_tbl(j).tax_amount ;
5449: END IF;
5450: END LOOP;
5451: /* getting total tax value from oe_order_lines_all table for line id*/
5452: SELECT TAX_VALUE
5453: INTO l_old_total_tax
5454: FROM oe_order_lines_all
5455: WHERE line_id = p_entity_id_tbl(i).entity_id;

Line 5454: FROM oe_order_lines_all

5450: END LOOP;
5451: /* getting total tax value from oe_order_lines_all table for line id*/
5452: SELECT TAX_VALUE
5453: INTO l_old_total_tax
5454: FROM oe_order_lines_all
5455: WHERE line_id = p_entity_id_tbl(i).entity_id;
5456:
5457: l_line_rec := OE_line_UTIL.Query_Row(p_line_id=> p_entity_id_tbl(i).entity_id );
5458:

Line 5467: /* updating the tax value and tax line value on oe_order_lines_all table for line id*/

5463: IF l_debug_level > 0 THEN
5464: oe_debug_pub.add('Updateing tax value from '||TO_CHAR(l_old_total_tax)|| ' To ' ||TO_CHAR(l_total_tax) ,2);
5465: END IF;
5466:
5467: /* updating the tax value and tax line value on oe_order_lines_all table for line id*/
5468: UPDATE OE_ORDER_LINES_ALL
5469: SET TAX_VALUE = l_total_tax,
5470: TAX_LINE_VALUE = l_total_tax - l_tax_on_charge --TaxER
5471: WHERE line_id = p_entity_id_tbl(i).entity_id;

Line 5468: UPDATE OE_ORDER_LINES_ALL

5464: oe_debug_pub.add('Updateing tax value from '||TO_CHAR(l_old_total_tax)|| ' To ' ||TO_CHAR(l_total_tax) ,2);
5465: END IF;
5466:
5467: /* updating the tax value and tax line value on oe_order_lines_all table for line id*/
5468: UPDATE OE_ORDER_LINES_ALL
5469: SET TAX_VALUE = l_total_tax,
5470: TAX_LINE_VALUE = l_total_tax - l_tax_on_charge --TaxER
5471: WHERE line_id = p_entity_id_tbl(i).entity_id;
5472: /* getting line record*/

Line 5476: FROM oe_order_lines_all

5472: /* getting line record*/
5473: --TaxER l_line_rec := OE_line_UTIL.Query_Row(p_line_id=> p_entity_id_tbl(i).entity_id );
5474: SELECT payment_type_code
5475: INTO l_payment_type_code
5476: FROM oe_order_lines_all
5477: WHERE line_id = l_line_rec.line_id;
5478: -- Bug 8825061: Update the global picture given that the line attribute
5479: -- "tax_value" has undergone an update.
5480: IF l_debug_level > 0 THEN

Line 5777: FROM oe_order_lines_all

5773: END IF; -- check on l_debug_level
5774: /* getting return count*/
5775: SELECT COUNT(1)
5776: INTO l_return
5777: FROM oe_order_lines_all
5778: WHERE 1 =1
5779: AND header_id = l_header_rec.header_id
5780: AND line_category_code = 'RETURN';
5781: IF l_return = 0 THEN -- logging delayed requests only when return lines are zero

Line 6034: FROM OE_ORDER_LINES

6030: ,subinventory
6031: ,source_document_id
6032: ,source_document_line_id
6033: ,item_type_code
6034: FROM OE_ORDER_LINES
6035: WHERE header_id = p_header_id;
6036:
6037: CURSOR employee_id_cur(p_user_id in number) IS
6038: SELECT employee_id

Line 6164: Update Oe_Order_lines

6160: FOR k in 1..l_req_line_tbl.count
6161: LOOP
6162: IF (l_req_line_tbl(k).requisition_line_id is not null) then
6163: BEGIN
6164: Update Oe_Order_lines
6165: Set source_document_id = l_req_header_rec.requisition_header_id
6166: ,source_document_line_id = l_req_line_tbl(k).requisition_line_id
6167: ,source_document_type_id = OE_GLOBALS.G_ORDER_SOURCE_INTERNAL -- i.e 10 for internal
6168: ,orig_sys_document_ref= l_req_header_rec.segment1

Line 6170: where oe_order_lines.line_id = l_req_line_tbl(k).source_doc_line_reference;

6166: ,source_document_line_id = l_req_line_tbl(k).requisition_line_id
6167: ,source_document_type_id = OE_GLOBALS.G_ORDER_SOURCE_INTERNAL -- i.e 10 for internal
6168: ,orig_sys_document_ref= l_req_header_rec.segment1
6169: ,orig_sys_line_ref = l_req_line_tbl(k).line_num
6170: where oe_order_lines.line_id = l_req_line_tbl(k).source_doc_line_reference;
6171: END;
6172: END IF;
6173: END LOOP;
6174: oe_debug_pub.add('auto_create_internal_req after line update ',2);

Line 6227: l_cons_price_request_code OE_ORDER_LINES_ALL.price_request_code%TYPE;

6223: l_parent_line_id NUMBER;
6224: l_header_id NUMBER;
6225: --bug#7491829
6226:
6227: l_cons_price_request_code OE_ORDER_LINES_ALL.price_request_code%TYPE;
6228: l_ret_price_request_code OE_ORDER_LINES_ALL.price_request_code%TYPE;
6229:
6230: CURSOR REFERENCED_LINE is
6231: SELECT return.price_request_code,

Line 6228: l_ret_price_request_code OE_ORDER_LINES_ALL.price_request_code%TYPE;

6224: l_header_id NUMBER;
6225: --bug#7491829
6226:
6227: l_cons_price_request_code OE_ORDER_LINES_ALL.price_request_code%TYPE;
6228: l_ret_price_request_code OE_ORDER_LINES_ALL.price_request_code%TYPE;
6229:
6230: CURSOR REFERENCED_LINE is
6231: SELECT return.price_request_code,
6232: referenced.pricing_quantity,

Line 6234: FROM OE_ORDER_LINES_ALL return , OE_ORDER_LINES_ALL referenced

6230: CURSOR REFERENCED_LINE is
6231: SELECT return.price_request_code,
6232: referenced.pricing_quantity,
6233: referenced.price_request_code
6234: FROM OE_ORDER_LINES_ALL return , OE_ORDER_LINES_ALL referenced
6235: WHERE return.line_id = p_line_id
6236: and referenced.line_id = return.reference_line_id;
6237:
6238: --bug #7491829

Line 6243: FROM OE_ORDER_LINES_ALL child, OE_ORDER_LINES_ALL parent

6239: CURSOR SPLIT_LINE IS
6240: SELECT parent.header_id,
6241: parent.pricing_quantity,
6242: parent.line_id
6243: FROM OE_ORDER_LINES_ALL child, OE_ORDER_LINES_ALL parent
6244: WHERE child.line_id = p_line_id
6245: and parent.line_id = child.split_from_line_id;
6246: --bug #7491829
6247:

Line 6341: update oe_order_lines_All

6337: END IF;
6338:
6339: --bug 7491829
6340: IF p_action_code = 'SPLIT_NEW' THEN
6341: update oe_order_lines_All
6342: set price_request_code = l_ret_price_request_code
6343: where line_id = p_line_id;
6344: END IF;
6345: --bug 7491829

Line 6934: from oe_order_lines_all

6930: END IF;
6931: Begin
6932: select nvl(ordered_quantity,0)
6933: into l_new_ord_quantity
6934: from oe_order_lines_all
6935: where line_id = p_line_id;
6936: End;
6937: IF l_new_ord_quantity = 0 THEN
6938: IF l_debug_level > 0 THEN