DBA Data[Home] [Help]

APPS.OPI_PMI_IDS_SUMMARY dependencies on OPI_PMI_IDS_TEMP

Line 459: INSERT INTO opi_pmi_ids_temp (CO_CODE

455:
456:
457: edw_log.put_line ('Before moving rows to be re-summaeized to temp table :');
458:
459: INSERT INTO opi_pmi_ids_temp (CO_CODE
460: ,ORGN_CODE
461: ,WHSE_CODE
462: ,LOCATION
463: ,AVG_ONH_QTY

Line 533: from opi_pmi_ids_temp

529: order by trans_date ASC;
530: rec_summary summerize_temp_sum%ROWTYPE;
531: CURSOR get_records_to_change IS
532: select *
533: from opi_pmi_ids_temp
534: where co_code = rec_summary.co_code
535: AND whse_code = rec_summary.whse_code
536: AND orgn_code = rec_summary.orgn_code
537: AND Location = rec_summary.location

Line 582: UPDATE opi_pmi_ids_temp

578: EXIT when summerize_temp_sum%NOTFOUND;
579: BEGIN
580: /* update row if already a row exists for company,organization,warehouse,location
581: item,lot and transaction date */
582: UPDATE opi_pmi_ids_temp
583: SET wip_comp_qty = rec_summary.wip_comp_qty,
584: wip_issue_qty = rec_summary.wip_issue_qty,
585: po_del_qty = rec_summary.po_del_qty,
586: total_rec_qty = rec_summary.total_rec_qty,

Line 606: INSERT into opi_pmi_ids_temp ( co_code,

602: item,lot and transaction date combination then insert the row with operation code = 'INSERT'
603: */
604:
605: if sql%rowcount = 0 THEN
606: INSERT into opi_pmi_ids_temp ( co_code,
607: orgn_code,
608: whse_code,
609: location,
610: item_id,

Line 673: UPDATE opi_pmi_ids_temp

669: ids_bal_rec.end_onh_qty := NULL;
670: ids_bal_rec.beg_onh_qty := NULL;
671: ids_bal_rec.trx_date := NULL;
672: BEGIN
673: UPDATE opi_pmi_ids_temp
674: SET period_flag = 0
675: where co_code = rec_summary.co_code
676: AND whse_code = rec_summary.whse_code
677: AND orgn_code = rec_summary.orgn_code

Line 683: INSERT into opi_pmi_ids_temp ( co_code,

679: AND item_id = rec_summary.item_id
680: AND lot_id = rec_summary.lot_id
681: AND trx_Date = rec_summary.period_start_date;
682: IF sql%rowCOUNT = 0 THEN
683: INSERT into opi_pmi_ids_temp ( co_code,
684: orgn_code,
685: whse_code,
686: location,
687: item_id,

Line 731: UPDATE opi_pmi_ids_temp

727: sysdate,
728: sysdate,
729: 'INSERT');
730: END IF;
731: UPDATE opi_pmi_ids_temp
732: SET period_flag = 1
733: where co_code = rec_summary.co_code
734: AND whse_code = rec_summary.whse_code
735: AND orgn_code = rec_summary.orgn_code

Line 741: INSERT into opi_pmi_ids_temp ( co_code,

737: AND item_id = rec_summary.item_id
738: AND lot_id = rec_summary.lot_id
739: AND trx_Date = rec_summary.period_end_date;
740: IF SQL%ROWCOUNT = 0 THEN
741: INSERT into opi_pmi_ids_temp ( co_code,
742: orgn_code,
743: whse_code,
744: location,
745: item_id,

Line 790: UPDATE opi_pmi_ids_temp

786: sysdate,
787: 'INSERT');
788: END IF;
789: END;
790: UPDATE opi_pmi_ids_temp
791: SET period_flag = 0
792: where co_code = rec_summary.co_code
793: AND whse_code = rec_summary.whse_code
794: AND orgn_code = rec_summary.orgn_code

Line 799: UPDATE opi_pmi_ids_temp

795: AND Location = rec_summary.location
796: AND item_id = rec_summary.item_id
797: AND lot_id = rec_summary.lot_id
798: AND trx_Date = rec_summary.period_start_date;
799: UPDATE opi_pmi_ids_temp
800: SET period_flag = 1
801: where co_code = rec_summary.co_code
802: AND whse_code = rec_summary.whse_code
803: AND orgn_code = rec_summary.orgn_code

Line 823: INSERT into opi_pmi_ids_temp ( co_code,

819: *** organization,warehouse,location,item,lot and transaction date combination then we need to create period ***
820: *** marker rows till current period. ***
821: *********************************************************************************************************************/
822:
823: INSERT into opi_pmi_ids_temp ( co_code,
824: orgn_code,
825: whse_code,
826: location,
827: item_id,

Line 877: FROM opi_pmi_ids_temp summ,

873: summ.location location,
874: summ.item_id item_id,
875: summ.lot_id lot_id,
876: glcldr.start_date start_date
877: FROM opi_pmi_ids_temp summ,
878: opi_opm_gl_calendar_v glcldr
879: WHERE summ.period_flag = 1
880: and trunc(summ.trx_date) = trunc(rec_summary.period_end_date)
881: and summ.co_code = glcldr.co_code

Line 898: FROM opi_pmi_ids_temp summ,

894: summ.location location,
895: summ.item_id item_id,
896: summ.lot_id lot_id,
897: summ.trx_date start_date
898: FROM opi_pmi_ids_temp summ,
899: opi_opm_gl_calendar_v glcldr
900: WHERE trunc(summ.trx_date) >= trunc(rec_summary.period_end_date)
901: and summ.co_code = glcldr.co_code
902: and glcldr.start_date = summ.trx_date

Line 911: INSERT into opi_pmi_ids_temp ( co_code,

907: and summ.location = rec_summary.location
908: and summ.item_id = rec_summary.item_id
909: and summ.lot_id = rec_summary.lot_id)) p_marker_rows);
910:
911: INSERT into opi_pmi_ids_temp ( co_code,
912: orgn_code,
913: whse_code,
914: location,
915: item_id,

Line 965: FROM opi_pmi_ids_temp summ,

961: summ.location location,
962: summ.item_id item_id,
963: summ.lot_id lot_id,
964: glcldr.end_date end_date
965: FROM opi_pmi_ids_temp summ,
966: opi_opm_gl_calendar_v glcldr
967: WHERE summ.period_flag = 1
968: and trunc(summ.trx_date) = trunc(rec_summary.period_end_date)
969: and summ.co_code = glcldr.co_code

Line 986: FROM opi_pmi_ids_temp summ,

982: summ.location location,
983: summ.item_id item_id,
984: summ.lot_id lot_id,
985: summ.trx_date end_date
986: FROM opi_pmi_ids_temp summ,
987: opi_opm_gl_calendar_v glcldr
988: WHERE trunc(summ.trx_date) >= trunc(rec_summary.period_end_date)
989: and summ.co_code = glcldr.co_code
990: and glcldr.end_date = summ.trx_date

Line 1021: update opi_pmi_ids_temp

1017: l_n_beg_qty := l_prev_end_qty;
1018: l_n_end_qty := l_n_beg_qty + l_n_tr_qty;
1019: END IF;
1020: l_prev_end_qty := l_n_end_qty;
1021: update opi_pmi_ids_temp
1022: set
1023: AVG_ONH_QTY = (l_n_beg_qty+l_n_end_qty)/2,
1024: BEG_ONH_QTY = l_n_beg_qty,
1025: END_ONH_QTY = l_n_end_qty,

Line 1099: FROM opi_pmi_ids_temp

1095: ,TRX_DATE
1096: ,WIP_COMP_QTY
1097: ,WIP_ISSUE_QTY
1098: ,period_flag
1099: FROM opi_pmi_ids_temp
1100: WHERE OPERATION_CODE = 'INSERT');
1101:
1102: l_insert_row_cnt := sql%rowcount;
1103:

Line 1141: FROM opi_pmi_ids_temp tmp

1137: ,tmp.TO_ORG_QTY
1138: ,tmp.WIP_COMP_QTY
1139: ,tmp.WIP_ISSUE_QTY
1140: ,tmp.period_flag
1141: FROM opi_pmi_ids_temp tmp
1142: WHERE sm.CO_CODE = tmp.CO_CODE
1143: AND sm.ORGN_CODE = tmp.ORGN_CODE
1144: AND sm.WHSE_CODE = tmp.WHSE_CODE
1145: AND sm.LOCATION = tmp.LOCATION

Line 1151: FROM opi_pmi_ids_temp tmp

1147: AND sm.ITEM_ID = tmp.ITEM_ID
1148: AND sm.TRX_DATE = tmp.TRX_DATE
1149: AND tmp.OPERATION_CODE = 'UPDATE')
1150: where exists (select 1
1151: FROM opi_pmi_ids_temp tmp
1152: WHERE sm.CO_CODE = tmp.CO_CODE
1153: AND sm.ORGN_CODE = tmp.ORGN_CODE
1154: AND sm.WHSE_CODE = tmp.WHSE_CODE
1155: AND sm.LOCATION = tmp.LOCATION

Line 1403: where table_name= 'OPI_PMI_IDS_TEMP';

1399: END;
1400: END IF;
1401: select TABLE_OWNER INTO l_owner
1402: from user_synonyms
1403: where table_name= 'OPI_PMI_IDS_TEMP';
1404: IF l_owner IS NOT NULL THEN
1405: l_stmt := 'truncate table '||l_owner||'.opi_pmi_ids_temp ';
1406: BEGIN
1407: execute immediate l_stmt;

Line 1405: l_stmt := 'truncate table '||l_owner||'.opi_pmi_ids_temp ';

1401: select TABLE_OWNER INTO l_owner
1402: from user_synonyms
1403: where table_name= 'OPI_PMI_IDS_TEMP';
1404: IF l_owner IS NOT NULL THEN
1405: l_stmt := 'truncate table '||l_owner||'.opi_pmi_ids_temp ';
1406: BEGIN
1407: execute immediate l_stmt;
1408: EXCEPTION WHEN OTHERS THEN
1409: NULL;