DBA Data[Home] [Help]

APPS.GME_TRANS_ENGINE_UTIL dependencies on GME_INVENTORY_TXNS_GTMP

Line 30: FROM gme_inventory_txns_gtmp

26: IS
27: CURSOR c_get_init_reversal (v_doc_id NUMBER)
28: IS
29: SELECT *
30: FROM gme_inventory_txns_gtmp
31: -- WHERE ACTION_CODE ='REVL'; -- Should this be indexed.
32: WHERE transaction_no = 2 -- Should this be indexed.
33: AND trans_qty <>
34: 0

Line 60: FROM gme_inventory_txns_gtmp

56: ,v_qty NUMBER
57: ,v_trans_date DATE)
58: IS
59: SELECT *
60: FROM gme_inventory_txns_gtmp
61: WHERE transaction_no <> 2 -- Should this be indexed.
62: AND doc_id = v_doc_id
63: AND line_type = v_line_type
64: AND item_id = v_item_id

Line 86: FROM gme_inventory_txns_gtmp

82: ,v_completed_ind NUMBER
83: ,v_qty NUMBER)
84: IS
85: SELECT *
86: FROM gme_inventory_txns_gtmp
87: WHERE transaction_no <> 2 -- Should this be indexed.
88: AND doc_id = v_doc_id
89: AND line_type = v_line_type
90: AND item_id = v_item_id

Line 101: FROM gme_inventory_txns_gtmp

97:
98: CURSOR c_get_cmplt_zero_def_txns
99: IS
100: SELECT *
101: FROM gme_inventory_txns_gtmp
102: WHERE completed_ind = 1 AND trans_qty = 0
103: ORDER BY line_type
104: ,item_id
105: ,material_detail_id

Line 117: FROM gme_inventory_txns_gtmp

113: p_batch_id IN NUMBER
114: ,p_batch_type IN VARCHAR2)
115: IS
116: SELECT COUNT (1)
117: FROM gme_inventory_txns_gtmp
118: WHERE doc_id = p_batch_id AND doc_type = p_batch_type;
119:
120: l_last_txn c_get_cmplt_zero_def_txns%ROWTYPE;
121: l_current_txn c_get_cmplt_zero_def_txns%ROWTYPE;

Line 124: l_trans_no gme_inventory_txns_gtmp.transaction_no%TYPE;

120: l_last_txn c_get_cmplt_zero_def_txns%ROWTYPE;
121: l_current_txn c_get_cmplt_zero_def_txns%ROWTYPE;
122: init_revs c_get_init_reversal%ROWTYPE;
123: match_revs c_get_match_reversal%ROWTYPE;
124: l_trans_no gme_inventory_txns_gtmp.transaction_no%TYPE;
125: l_api_name CONSTANT VARCHAR2 (30) := 'LOAD_MAT_AND_RSC_TRANS';
126: l_mat_row_count NUMBER := 0;
127: l_rsc_row_count NUMBER := 0;
128: l_inv_exists NUMBER := 0;

Line 217: ELSE -- Now Populate The GME_INVENTORY_TXNS_GTMP table

213: CLOSE c_check_mat_transactions;
214:
215: IF (l_inv_exists > 0) THEN -- We have Alreay Loaded INV Batch Data
216: l_mat_row_count := l_inv_exists;
217: ELSE -- Now Populate The GME_INVENTORY_TXNS_GTMP table
218: -- Should this be in same file as other table routines */
219:
220: INSERT INTO gme_inventory_txns_gtmp
221: (trans_id,

Line 220: INSERT INTO gme_inventory_txns_gtmp

216: l_mat_row_count := l_inv_exists;
217: ELSE -- Now Populate The GME_INVENTORY_TXNS_GTMP table
218: -- Should this be in same file as other table routines */
219:
220: INSERT INTO gme_inventory_txns_gtmp
221: (trans_id,
222: item_id,
223: co_code,
224: orgn_code,

Line 374: UPDATE gme_inventory_txns_gtmp

370: || ' Is => '
371: || l_current_txn.trans_id);
372: END IF;
373:
374: UPDATE gme_inventory_txns_gtmp
375: -- SET ACTION_CODE = 'REVS'
376: SET transaction_no = 2
377: WHERE trans_id IN
378: (l_last_txn.trans_id, l_current_txn.trans_id);

Line 403: UPDATE gme_inventory_txns_gtmp

399:
400: /* Bug 2376240 - Thomas Daniel */
401: /* Added the action_code = NONE and the batch_id condition as the following update */
402: /* was updating the rows of previous batches which have been modified */
403: UPDATE gme_inventory_txns_gtmp
404: SET transaction_no = 2
405: WHERE action_code = 'NONE'
406: AND doc_id = p_batch_row.batch_id
407: AND ( (line_type = -1 AND trans_qty > 0)

Line 544: UPDATE gme_inventory_txns_gtmp

540: --BUG #3528006 END LOOP; /* FETCH c_get_match_reversal */
541: --BUG #3528006 CLOSE c_get_match_reversal;
542: -- 3187467 mark the reversal if matching txn found
543: IF l_match_rev_id IS NOT NULL THEN
544: UPDATE gme_inventory_txns_gtmp
545: SET transaction_no = 2
546: WHERE trans_id = l_match_rev_id;
547: END IF;
548: END LOOP; /* c_get_init_reversal INTO init_revs */

Line 594: p_tran_row IN gme_inventory_txns_gtmp%ROWTYPE

590: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
591: END load_mat_and_rsc_trans;
592:
593: FUNCTION build_trans_rec (
594: p_tran_row IN gme_inventory_txns_gtmp%ROWTYPE
595: ,x_tran_rec OUT NOCOPY gmi_trans_engine_pub.ictran_rec)
596: RETURN BOOLEAN
597: IS
598: l_api_name CONSTANT VARCHAR2 (30) := 'BUILD_TRANS_REC';

Line 845: UPDATE gme_inventory_txns_gtmp

841: IF l_return_status <> x_return_status OR l_def_trans_id IS NULL THEN
842: RAISE error_fetch_def_lot_id;
843: END IF;
844:
845: UPDATE gme_inventory_txns_gtmp
846: SET def_trans_ind = 1
847: WHERE trans_id = l_def_trans_id;
848: END LOOP;
849: EXCEPTION

Line 914: ,v_doc_type gme_inventory_txns_gtmp.doc_type%TYPE)

910:
911: CURSOR cur_get_def_trans (
912: v_batch_id gme_batch_header.batch_id%TYPE
913: ,v_line_id gme_material_details.material_detail_id%TYPE
914: ,v_doc_type gme_inventory_txns_gtmp.doc_type%TYPE)
915: IS
916: SELECT trans_id, whse_code
917: FROM gme_inventory_txns_gtmp
918: WHERE doc_id = v_batch_id

Line 917: FROM gme_inventory_txns_gtmp

913: ,v_line_id gme_material_details.material_detail_id%TYPE
914: ,v_doc_type gme_inventory_txns_gtmp.doc_type%TYPE)
915: IS
916: SELECT trans_id, whse_code
917: FROM gme_inventory_txns_gtmp
918: WHERE doc_id = v_batch_id
919: AND doc_type = v_doc_type
920: AND material_detail_id = v_line_id
921: AND lot_id = 0

Line 947: l_doc_type gme_inventory_txns_gtmp.doc_type%TYPE;

943: l_tran_whse ps_whse_eff.whse_code%TYPE;
944: l_return_status VARCHAR2 (1);
945: l_api_name CONSTANT VARCHAR2 (30) := 'GET_DEFAULT_LOT';
946: l_batch_type gme_batch_header.batch_type%TYPE;
947: l_doc_type gme_inventory_txns_gtmp.doc_type%TYPE;
948: l_cnt NUMBER;
949: error_deduce_trans_whse EXCEPTION;
950: -- corrupt_batch EXCEPTION;
951: BEGIN

Line 979: FROM gme_inventory_txns_gtmp

975: END IF;
976:
977: SELECT COUNT (1)
978: INTO l_cnt
979: FROM gme_inventory_txns_gtmp
980: WHERE doc_id = l_matl_dtl.batch_id
981: AND doc_type = l_doc_type
982: AND material_detail_id = p_line_id
983: AND transaction_no <> 2

Line 991: FROM gme_inventory_txns_gtmp

987: -- This is the default lot for sure, because there can only at most one zero qty txn, completed
988: -- or pending. No need for further processing.
989: SELECT trans_id
990: INTO x_def_trans_id
991: FROM gme_inventory_txns_gtmp
992: WHERE doc_id = l_matl_dtl.batch_id
993: AND doc_type = l_doc_type
994: AND material_detail_id = p_line_id
995: AND transaction_no <> 2

Line 1098: UPDATE gme_inventory_txns_gtmp g

1094: l_api_name CONSTANT VARCHAR2 (30) := 'SET_DEFAULT_LOT_FOR_NEW_BATCH';
1095: BEGIN
1096: x_return_status := fnd_api.g_ret_sts_success;
1097:
1098: UPDATE gme_inventory_txns_gtmp g
1099: SET def_trans_ind = 1
1100: WHERE trans_id = (SELECT MIN (trans_id)
1101: FROM gme_inventory_txns_gtmp
1102: WHERE material_detail_id = g.material_detail_id);

Line 1101: FROM gme_inventory_txns_gtmp

1097:
1098: UPDATE gme_inventory_txns_gtmp g
1099: SET def_trans_ind = 1
1100: WHERE trans_id = (SELECT MIN (trans_id)
1101: FROM gme_inventory_txns_gtmp
1102: WHERE material_detail_id = g.material_detail_id);
1103: EXCEPTION
1104: WHEN OTHERS THEN
1105: x_return_status := fnd_api.g_ret_sts_unexp_error;