DBA Data[Home] [Help]

APPS.WIP_JOB_DTLS_VALIDATIONS dependencies on WIP_JOB_DETAILS

Line 32: if(wip_job_details.std_alone = 0) then

28:
29: l_interface_id NUMBER;
30: l_error_exists boolean := false;
31: begin
32: if(wip_job_details.std_alone = 0) then
33: open c_ml_invalid_rows;
34: else
35: open c_wdj_invalid_rows;
36: end if;

Line 39: if(wip_job_details.std_alone = 0) then

35: open c_wdj_invalid_rows;
36: end if;
37:
38: loop
39: if(wip_job_details.std_alone = 0) then
40: fetch c_ml_invalid_rows into l_interface_id;
41: exit when c_ml_invalid_rows%NOTFOUND;
42: else
43: fetch c_wdj_invalid_rows into l_interface_id;

Line 49: if(wip_job_details.std_alone = 1) then

45: end if;
46: l_error_exists := true; --loop executes only for invalid rows!
47: fnd_message.set_name('WIP', 'WIP_JOB_DOES_NOT_EXIST');
48: fnd_message.set_token('INTERFACE', to_char(l_interface_id));
49: if(wip_job_details.std_alone = 1) then
50: wip_interface_err_Utils.add_error(p_interface_id => l_interface_id,
51: p_text => substr(fnd_message.get,1,500),
52: p_error_type => wip_jdi_utils.msg_error);
53: else

Line 68: if(wip_job_details.std_alone = 1) then

64: close c_wdj_invalid_rows;
65: end if;
66:
67: if(l_error_exists) then
68: if(wip_job_details.std_alone = 1) then
69: update wip_job_dtls_interface wjdi
70: set process_status = wip_constants.error
71: where wjdi.group_id = p_group_id
72: and process_phase = wip_constants.ml_validation

Line 120: if(wip_job_details.std_alone = 1) then

116: -- 1: unreleased, no charges allowed
117: -- 3: released, charges allowed
118: -- 4: complete, charges allowed
119: -- 6: hold, no charges allowed
120: if(wip_job_details.std_alone = 1) then
121: for l_inv_row in c_ml_invalid_rows loop
122: l_error_exists := true; --loop executes only for invalid rows!
123: fnd_message.set_name('WIP', 'WIP_JOB_INVALID_STATUS');
124: fnd_message.set_token('INTERFACE', to_char(l_inv_row.interface_id));

Line 173: if(wip_job_details.std_alone = 1) then

169:
170: l_error_exists boolean := false;
171: begin
172: -- If firmed, we can't do any further change
173: if(wip_job_details.std_alone = 1) then
174: for l_inv_row in c_invalid_rows loop
175: l_error_exists := true;
176: fnd_message.set_name('WIP', 'WIP_JOB_FIRMED');
177: fnd_message.set_token('INTERFACE', to_char(l_inv_row.interface_id));

Line 223: and ( wjdi.load_type in (wip_job_details.wip_resource,

219: and wjdi.parent_header_id = p_parent_header_id
220: and wjdi.process_phase = wip_constants.ml_validation
221: and wjdi.process_status in (wip_constants.running,
222: wip_constants.warning)
223: and ( wjdi.load_type in (wip_job_details.wip_resource,
224: wip_job_details.wip_sub_res,
225: wip_job_details.wip_res_usage)
226:
227: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement

Line 224: wip_job_details.wip_sub_res,

220: and wjdi.process_phase = wip_constants.ml_validation
221: and wjdi.process_status in (wip_constants.running,
222: wip_constants.warning)
223: and ( wjdi.load_type in (wip_job_details.wip_resource,
224: wip_job_details.wip_sub_res,
225: wip_job_details.wip_res_usage)
226:
227: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement
228: and wjdi.operation_seq_num <> 1

Line 225: wip_job_details.wip_res_usage)

221: and wjdi.process_status in (wip_constants.running,
222: wip_constants.warning)
223: and ( wjdi.load_type in (wip_job_details.wip_resource,
224: wip_job_details.wip_sub_res,
225: wip_job_details.wip_res_usage)
226:
227: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement
228: and wjdi.operation_seq_num <> 1
229: )

Line 227: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement

223: and ( wjdi.load_type in (wip_job_details.wip_resource,
224: wip_job_details.wip_sub_res,
225: wip_job_details.wip_res_usage)
226:
227: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement
228: and wjdi.operation_seq_num <> 1
229: )
230: )
231: and not exists (select 1

Line 246: and ( wjdi.load_type in (wip_job_details.wip_resource,

242: and wjdi.process_status in (wip_constants.running,
243: wip_constants.warning)
244: and wjdi.wip_entity_id = p_wip_entity_id
245: and wjdi.organization_id = p_organization_id
246: and ( wjdi.load_type in (wip_job_details.wip_resource,
247: wip_job_details.wip_sub_res,
248: wip_job_details.wip_res_usage)
249:
250: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement

Line 247: wip_job_details.wip_sub_res,

243: wip_constants.warning)
244: and wjdi.wip_entity_id = p_wip_entity_id
245: and wjdi.organization_id = p_organization_id
246: and ( wjdi.load_type in (wip_job_details.wip_resource,
247: wip_job_details.wip_sub_res,
248: wip_job_details.wip_res_usage)
249:
250: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement
251: and wjdi.operation_seq_num <> 1

Line 248: wip_job_details.wip_res_usage)

244: and wjdi.wip_entity_id = p_wip_entity_id
245: and wjdi.organization_id = p_organization_id
246: and ( wjdi.load_type in (wip_job_details.wip_resource,
247: wip_job_details.wip_sub_res,
248: wip_job_details.wip_res_usage)
249:
250: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement
251: and wjdi.operation_seq_num <> 1
252: )

Line 250: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement

246: and ( wjdi.load_type in (wip_job_details.wip_resource,
247: wip_job_details.wip_sub_res,
248: wip_job_details.wip_res_usage)
249:
250: or ( wjdi.load_type = wip_job_details.wip_mtl_requirement
251: and wjdi.operation_seq_num <> 1
252: )
253: )
254: and not exists (select 1

Line 278: and load_type = wip_job_details.wip_mtl_requirement

274: and process_phase = wip_constants.ml_validation
275: and process_status in (wip_constants.running,wip_constants.warning)
276: and wip_entity_id = p_wip_entity_id
277: and organization_id = p_organization_id
278: and load_type = wip_job_details.wip_mtl_requirement
279: and substitution_type = wip_job_details.wip_add
280: and operation_seq_num = 1;
281:
282: if(l_num_first_op_rows > 0) then

Line 279: and substitution_type = wip_job_details.wip_add

275: and process_status in (wip_constants.running,wip_constants.warning)
276: and wip_entity_id = p_wip_entity_id
277: and organization_id = p_organization_id
278: and load_type = wip_job_details.wip_mtl_requirement
279: and substitution_type = wip_job_details.wip_add
280: and operation_seq_num = 1;
281:
282: if(l_num_first_op_rows > 0) then
283: --get the first op seq number

Line 298: and load_type = wip_job_details.wip_mtl_requirement

294: and process_phase = wip_constants.ml_validation
295: and process_status in (wip_constants.running, wip_constants.warning)
296: and wip_entity_id = p_wip_entity_id
297: and organization_id = p_organization_id
298: and load_type = wip_job_details.wip_mtl_requirement
299: and substitution_type = wip_job_details.wip_add
300: and operation_seq_num = 1;
301: end if ;
302: end if;

Line 299: and substitution_type = wip_job_details.wip_add

295: and process_status in (wip_constants.running, wip_constants.warning)
296: and wip_entity_id = p_wip_entity_id
297: and organization_id = p_organization_id
298: and load_type = wip_job_details.wip_mtl_requirement
299: and substitution_type = wip_job_details.wip_add
300: and operation_seq_num = 1;
301: end if ;
302: end if;
303: close c_first_operation;

Line 306: if(wip_job_details.std_alone = 1) then

302: end if;
303: close c_first_operation;
304: end if;
305: -- operation_seq_num must be in job
306: if(wip_job_details.std_alone = 1) then
307: open c_wdj_invalid_rows;
308: else
309: open c_ml_invalid_rows;
310: end if;

Line 313: if(wip_job_details.std_alone = 0) then

309: open c_ml_invalid_rows;
310: end if;
311:
312: loop
313: if(wip_job_details.std_alone = 0) then
314: fetch c_ml_invalid_rows into l_interface_id;
315: exit when c_ml_invalid_rows%NOTFOUND;
316: else
317: fetch c_wdj_invalid_rows into l_interface_id;

Line 323: if(wip_job_details.std_alone = 1) then

319: end if;
320: l_error_exists := true; --loop executes only for invalid rows!
321: fnd_message.set_name('WIP', 'WIP_OP_NOT_FOUND');
322: fnd_message.set_token('INTERFACE', to_char(l_interface_id));
323: if(wip_job_details.std_alone = 1) then
324: wip_interface_err_Utils.add_error(p_interface_id => l_interface_id,
325: p_text => substr(fnd_message.get,1,500),
326: p_error_type => wip_jdi_utils.msg_error);
327: else

Line 342: if(wip_job_details.std_alone = 1) then

338: close c_wdj_invalid_rows;
339: end if;
340:
341: if(l_error_exists) then
342: if(wip_job_details.std_alone = 1) then
343: update wip_job_dtls_interface wjdi
344: set process_status = wip_constants.error
345: where group_id = p_group_id
346: and process_phase = wip_constants.ml_validation

Line 351: and ( load_type in (wip_job_details.wip_resource,

347: and process_status in (wip_constants.running,
348: wip_constants.warning)
349: and wip_entity_id = p_wip_entity_id
350: and organization_id = p_organization_id
351: and ( load_type in (wip_job_details.wip_resource,
352: wip_job_details.wip_sub_res,
353: wip_job_details.wip_res_usage)
354:
355: or ( load_type = wip_job_details.wip_mtl_requirement

Line 352: wip_job_details.wip_sub_res,

348: wip_constants.warning)
349: and wip_entity_id = p_wip_entity_id
350: and organization_id = p_organization_id
351: and ( load_type in (wip_job_details.wip_resource,
352: wip_job_details.wip_sub_res,
353: wip_job_details.wip_res_usage)
354:
355: or ( load_type = wip_job_details.wip_mtl_requirement
356: and operation_seq_num <> 1

Line 353: wip_job_details.wip_res_usage)

349: and wip_entity_id = p_wip_entity_id
350: and organization_id = p_organization_id
351: and ( load_type in (wip_job_details.wip_resource,
352: wip_job_details.wip_sub_res,
353: wip_job_details.wip_res_usage)
354:
355: or ( load_type = wip_job_details.wip_mtl_requirement
356: and operation_seq_num <> 1
357: )

Line 355: or ( load_type = wip_job_details.wip_mtl_requirement

351: and ( load_type in (wip_job_details.wip_resource,
352: wip_job_details.wip_sub_res,
353: wip_job_details.wip_res_usage)
354:
355: or ( load_type = wip_job_details.wip_mtl_requirement
356: and operation_seq_num <> 1
357: )
358: )
359: and not exists (select 1

Line 372: and ( load_type in (wip_job_details.wip_resource,

368: and parent_header_id = p_parent_header_id
369: and process_phase = wip_constants.ml_validation
370: and process_status in (wip_constants.running,
371: wip_constants.warning)
372: and ( load_type in (wip_job_details.wip_resource,
373: wip_job_details.wip_sub_res,
374: wip_job_details.wip_res_usage)
375:
376: or ( load_type = wip_job_details.wip_mtl_requirement

Line 373: wip_job_details.wip_sub_res,

369: and process_phase = wip_constants.ml_validation
370: and process_status in (wip_constants.running,
371: wip_constants.warning)
372: and ( load_type in (wip_job_details.wip_resource,
373: wip_job_details.wip_sub_res,
374: wip_job_details.wip_res_usage)
375:
376: or ( load_type = wip_job_details.wip_mtl_requirement
377: and operation_seq_num <> 1

Line 374: wip_job_details.wip_res_usage)

370: and process_status in (wip_constants.running,
371: wip_constants.warning)
372: and ( load_type in (wip_job_details.wip_resource,
373: wip_job_details.wip_sub_res,
374: wip_job_details.wip_res_usage)
375:
376: or ( load_type = wip_job_details.wip_mtl_requirement
377: and operation_seq_num <> 1
378: )

Line 376: or ( load_type = wip_job_details.wip_mtl_requirement

372: and ( load_type in (wip_job_details.wip_resource,
373: wip_job_details.wip_sub_res,
374: wip_job_details.wip_res_usage)
375:
376: or ( load_type = wip_job_details.wip_mtl_requirement
377: and operation_seq_num <> 1
378: )
379: )
380: and not exists (select 1

Line 404: and ( wjdi.load_type not in (1, 2, 3, 4, 5, 6, 7, WIP_JOB_DETAILS.WIP_RES_INSTANCE, WIP_JOB_DETAILS.WIP_RES_INSTANCE_USAGE) -- load_type must be resource or material

400: and wjdi.process_status in (wip_constants.running,
401: wip_constants.warning)
402: and wjdi.wip_entity_id = p_wip_entity_id
403: and wjdi.organization_id = p_organization_id
404: and ( wjdi.load_type not in (1, 2, 3, 4, 5, 6, 7, WIP_JOB_DETAILS.WIP_RES_INSTANCE, WIP_JOB_DETAILS.WIP_RES_INSTANCE_USAGE) -- load_type must be resource or material
405:
406:
407: or wjdi.substitution_type not in (1, 2, 3)); -- substitution_type must be delete or add or change
408:

Line 416: if(wip_job_details.std_alone = 1) then

412: for l_inv_row in c_invalid_rows loop
413: l_error_exists := true;
414: fnd_message.set_name('WIP', 'WIP_INVALID_LOAD_SUB_TYPE');
415: fnd_message.set_token('INTERFACE', to_char(l_inv_row.interface_id));
416: if(wip_job_details.std_alone = 1) then
417: wip_interface_err_Utils.add_error(p_interface_id => l_inv_row.interface_id,
418: p_text => substr(fnd_message.get,1,500),
419: p_error_type => wip_jdi_utils.msg_error);
420: else

Line 471: if(wip_job_details.std_alone = 1) then

467: for l_inv_row in c_invalid_rows loop
468: l_error_exists := true;
469: fnd_message.set_name('WIP', 'WIP_ML_LAST_UPDATED_BY');
470: fnd_message.set_token('INTERFACE', to_char(l_inv_row.interface_id));
471: if(wip_job_details.std_alone = 1) then
472: wip_interface_err_Utils.add_error(p_interface_id => l_inv_row.interface_id,
473: p_text => substr(fnd_message.get,1,500),
474: p_error_type => wip_jdi_utils.msg_error);
475: else

Line 526: if(wip_job_details.std_alone = 1) then

522: for l_inv_row in c_invalid_rows loop
523: l_error_exists := true;
524: fnd_message.set_name('WIP', 'WIP_ML_CREATED_BY');
525: fnd_message.set_token('INTERFACE', to_char(l_inv_row.interface_id));
526: if(wip_job_details.std_alone = 1) then
527: wip_interface_err_Utils.add_error(p_interface_id => l_inv_row.interface_id,
528: p_text => substr(fnd_message.get,1,500),
529: p_error_type => wip_jdi_utils.msg_error);
530: else