[Home] [Help]
81: into l_forecast_header_id,
82: l_period_set_name,
83: l_start_period,
84: l_start_date
85: from ce_forecasts
86: where forecast_id = X_forecast_id;
87: else
88: l_forecast_header_id := X_forecast_header_id;
89: l_period_set_name := X_period_set_name;
206: --------------------------------------------------------------------- */
207:
208: PROCEDURE Create_Dummy_Rows (X_forecast_header_id NUMBER) IS
209: CURSOR C_fc IS SELECT forecast_id
210: FROM ce_forecasts
211: WHERE forecast_header_id = X_forecast_header_id;
212: CURSOR C_frow(p_forecast_id NUMBER) IS SELECT forecast_row_id
213: FROM ce_forecast_rows
214: WHERE forecast_header_id = X_forecast_header_id
556:
557: if X_forecast_id is not null then
558: select nvl(drilldown_flag,'N')
559: into l_drilldown_flag
560: from ce_forecasts
561: where forecast_id = X_forecast_id;
562:
563: UPDATE ce_forecasts
564: SET forecast_header_id = l_forecast_header_id
559: into l_drilldown_flag
560: from ce_forecasts
561: where forecast_id = X_forecast_id;
562:
563: UPDATE ce_forecasts
564: SET forecast_header_id = l_forecast_header_id
565: WHERE forecast_id = X_forecast_id;
566:
567: if l_drilldown_flag = 'Y' then
1096: WHERE forecast_header_id = p_forecast_header_id;
1097:
1098: IF (p_start_project_num is null AND p_end_project_num is null
1099: AND nvl(p_sub_request,'N') = 'N') THEN
1100: CE_FORECASTS_TABLE_PKG.Insert_Row(
1101: X_Rowid => l_forecast_rowid,
1102: X_forecast_id => l_forecast_id,
1103: X_forecast_header_id => p_forecast_header_id,
1104: X_name => p_forecast_name,
1227: '','','','','','','','','','',
1228: '','','','','','','','','','');
1229: END IF;
1230:
1231: UPDATE ce_forecasts
1232: SET request_id = l_request_id
1233: WHERE forecast_id = l_forecast_id;
1234:
1235: EXCEPTION
1257:
1258: PROCEDURE Refresh_Processing_Status IS
1259: CURSOR C_fc IS SELECT forecast_id,
1260: request_id
1261: FROM ce_forecasts
1262: WHERE error_status in ('P','R','X')
1263: AND request_id is not null;
1264: call_status BOOLEAN;
1265: rphase VARCHAR2(80);
1271: FOR p_fc in C_fc LOOP
1272: call_status := FND_CONCURRENT.GET_REQUEST_STATUS(p_fc.request_id,'','',
1273: rphase, rstatus, dphase, dstatus, message);
1274: IF (dstatus in ('ERROR','CANCELLED','TERMINATED')) THEN
1275: UPDATE ce_forecasts
1276: SET error_status = 'F'
1277: WHERE forecast_id = p_fc.forecast_id;
1278: END IF;
1279: IF (dphase = 'RUNNING') THEN
1276: SET error_status = 'F'
1277: WHERE forecast_id = p_fc.forecast_id;
1278: END IF;
1279: IF (dphase = 'RUNNING') THEN
1280: UPDATE ce_forecasts
1281: SET error_status = 'R'
1282: WHERE forecast_id = p_fc.forecast_id
1283: AND error_status = 'P';
1284: END IF;