DBA Data[Home] [Help]

APPS.GMF_LAYERS dependencies on GMF_OUTGOING_MATERIAL_LAYERS

Line 387: FROM gmf_outgoing_material_layers l, mtl_material_transactions mmt

383: BEGIN
384: /* PK Bug 8219507 removed mtln */
385: SELECT -l.layer_doc_qty, l.layer_doc_um
386: INTO l_doc_qty, l_doc_um
387: FROM gmf_outgoing_material_layers l, mtl_material_transactions mmt
388: -- mtl_transaction_lot_numbers mtln
389: WHERE
390: mmt.transaction_id = p_tran_rec.reverse_id AND
391: -- mtln.transaction_id (+) = p_tran_rec.reverse_id AND

Line 441: FROM gmf_outgoing_material_layers l,

437: nvl(l.lot_number,'X')=nvl(p_tran_rec.lot_number,'X') */
438:
439: SELECT -sum(nvl(consume_ib_doc_qty,0)), l.ROWID
440: INTO l_rev_consume_ib_doc_qty, l_rowid
441: FROM gmf_outgoing_material_layers l,
442: gmf_batch_vib_details v
443: WHERE l.mmt_transaction_id = p_tran_rec.reverse_id and
444: nvl(l.lot_number,'X')= nvl(p_tran_rec.lot_number,'X') and
445: l.layer_id = v.consume_layer_id (+)

Line 458: UPDATE gmf_outgoing_material_layers

454: IF l_rev_consume_ib_doc_qty = 0 THEN
455: l_delete_mark := 1;
456: END IF;
457:
458: UPDATE gmf_outgoing_material_layers
459: SET remaining_ib_doc_qty = 0,
460: delete_mark = l_delete_mark
461: WHERE
462: ROWID = l_rowid;

Line 624: INSERT INTO gmf_outgoing_material_layers(

620: IF g_debug <= gme_debug.g_log_statement THEN
621: gme_debug.put_line ('creating new outgoing layers...');
622: END IF;
623:
624: INSERT INTO gmf_outgoing_material_layers(
625: layer_id,
626: mmt_transaction_id,
627: mmt_organization_id,
628: lot_number,

Line 1105: FROM gmf_outgoing_material_layers ol

1101: AND t.transaction_source_type_id = 5
1102: );
1103:
1104: DELETE
1105: FROM gmf_outgoing_material_layers ol
1106: WHERE (ol.mmt_organization_id, ol.mmt_transaction_id) IN
1107: (SELECT distinct t.organization_id, t.transaction_id
1108: FROM gme_batch_header h, mtl_material_transactions t
1109: WHERE h.batch_id = p_batch_id

Line 1244: Quanity CONSUME_IB_DOC_QTY needs to be added to REMAINING_IB_DOC_QTY of gmf_outgoing_material_layers or gmf_resource_layers.

1240: PROD_LAYER_ID (These will be deleted.) CONSUME_LAYER_ID ( Quantity needs to be added to this layer)
1241: CONSUME_LAYER_DATE ( Add quantity if CONSUME_LAYER_DATE is in a past period.
1242: That is CONSUME_LAYER_DATE < (select start_date from gmf_period_statuses where period_id = p_period_id)
1243: CONSUME_IB_DOC_QTY, CONSUME_IB_PRI_QTY.
1244: Quanity CONSUME_IB_DOC_QTY needs to be added to REMAINING_IB_DOC_QTY of gmf_outgoing_material_layers or gmf_resource_layers.
1245: Note that CONSUME_LAYER_ID could either belong to gmf_outgoing_material_layers or gmf_resource_layers.
1246: LINE_TYPE will decide whether it is outgoing layer or resource layer.
1247:
1248: */

Line 1245: Note that CONSUME_LAYER_ID could either belong to gmf_outgoing_material_layers or gmf_resource_layers.

1241: CONSUME_LAYER_DATE ( Add quantity if CONSUME_LAYER_DATE is in a past period.
1242: That is CONSUME_LAYER_DATE < (select start_date from gmf_period_statuses where period_id = p_period_id)
1243: CONSUME_IB_DOC_QTY, CONSUME_IB_PRI_QTY.
1244: Quanity CONSUME_IB_DOC_QTY needs to be added to REMAINING_IB_DOC_QTY of gmf_outgoing_material_layers or gmf_resource_layers.
1245: Note that CONSUME_LAYER_ID could either belong to gmf_outgoing_material_layers or gmf_resource_layers.
1246: LINE_TYPE will decide whether it is outgoing layer or resource layer.
1247:
1248: */
1249: FOR vib IN CUR_VIB_DETAILS LOOP

Line 1253: Update gmf_outgoing_material_layers

1249: FOR vib IN CUR_VIB_DETAILS LOOP
1250:
1251: IF vib.LINE_TYPE IN (-1, 2) THEN
1252:
1253: Update gmf_outgoing_material_layers
1254: set REMAINING_IB_DOC_QTY = REMAINING_IB_DOC_QTY + vib.CONSUME_IB_DOC_QTY
1255: where layer_id = vib.CONSUME_LAYER_ID;
1256:
1257: ELSIF vib.LINE_TYPE = 0 THEN

Line 1290: FROM gmf_outgoing_material_layers ol

1286: AND il.layer_date >= l_start_date
1287: );
1288:
1289: DELETE
1290: FROM gmf_outgoing_material_layers ol
1291: WHERE (ol.mmt_organization_id, ol.mmt_transaction_id) IN
1292: (SELECT distinct t.organization_id, t.transaction_id
1293: FROM gme_batch_header h, mtl_material_transactions t
1294: WHERE h.batch_id = p_batch_id

Line 1534: FROM gmf_outgoing_material_layers

1530: l_trans_rec.last_update_login := trans_rec.last_update_login;
1531:
1532: SELECT count(*)
1533: INTO l_count
1534: FROM gmf_outgoing_material_layers
1535: WHERE
1536: mmt_transaction_id = trans_rec.transaction_id
1537: AND ((lot_number is not null and lot_number = trans_rec.lot_number)
1538: OR

Line 1994: FROM gmf_outgoing_material_layers

1990: ;
1991: ELSE
1992: SELECT count(*)
1993: INTO l_count
1994: FROM gmf_outgoing_material_layers
1995: WHERE
1996: mmt_transaction_id = trans_rec.transaction_id
1997: AND ((lot_number is not null and lot_number = trans_rec.lot_number)
1998: OR

Line 2607: FROM gmf_outgoing_material_layers ol

2603: AND t.transaction_source_type_id = 5
2604: );
2605: fnd_file.put_line(fnd_file.log, ' Incoming layers count = '|| l_count);
2606: SELECT count(*) INTO l_count
2607: FROM gmf_outgoing_material_layers ol
2608: WHERE (ol.mmt_organization_id, ol.mmt_transaction_id) IN
2609: (SELECT DISTINCT t.organization_id, t.transaction_id
2610: FROM gme_batch_header h, mtl_material_transactions t
2611: WHERE h.batch_id = rec.batch_id