DBA Data[Home] [Help]

APPS.MRP_AP_REL_PLAN_PUB dependencies on WIP_JOB_DTLS_INTERFACE

Line 63: FROM WIP_JOB_DTLS_INTERFACE jdi

59: UPDATE wip_job_schedule_interface i
60: SET i.scheduling_method=1
61: WHERE
62: EXISTS(SELECT 1
63: FROM WIP_JOB_DTLS_INTERFACE jdi
64: WHERE jdi.group_id=G_OPM_WIP_GROUP_ID
65: AND jdi.parent_header_id = i.header_id
66: AND ROWNUM=1)
67: AND i.group_id = G_OPM_WIP_GROUP_ID

Line 2055: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

2051: ||' Maximum_Assigned_Units,'
2052: ||' USAGE_RATE_OR_AMOUNT,'
2053: ||' SCHEDULED_FLAG ,'
2054: ||' PARENT_SEQ_NUM '
2055: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
2056: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
2057: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
2058: ||' AND nvl(CFM_ROUTING_FLAG,0) = 3';
2059:

Line 2246: 'INSERT INTO WIP_JOB_DTLS_INTERFACE'

2242:
2243: EXECUTE IMMEDIATE lv_sqlstmt USING lv_instance_id,G_WIP_GROUP_ID;
2244:
2245: lv_sqlstmt:=
2246: 'INSERT INTO WIP_JOB_DTLS_INTERFACE'
2247: ||' ( INTERFACE_ID,'
2248: ||' GROUP_ID,'
2249: ||' OPERATION_SEQ_NUM,'
2250: ||' RESOURCE_SEQ_NUM,'

Line 2395: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

2391: ||' , maximum_assigned_units '
2392: ||' , parent_seq_num '
2393: ||' , firm_flag '
2394: ||' , schedule_seq_num '
2395: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
2396: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
2397: ||' AND nvl(CFM_ROUTING_FLAG,0) <> 3 '
2398: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
2399: ||' AND nvl(operation_seq_num,-1) <> -1'

Line 3182: wip_job_dtls_interface b,

3178:
3179: Cursor C1 is
3180: Select a.header_id,min(bos.operation_seq_num) new_op_seq
3181: from wip_job_schedule_interface a,
3182: wip_job_dtls_interface b,
3183: bom_operation_Sequences bos,
3184: bom_operational_routings bor
3185: where a.group_id = b.group_id
3186: and a.header_id = b.parent_header_id --added for the bug#3538800

Line 3210: wip_job_dtls_interface b

3206: b.INVENTORY_ITEM_ID_OLD,
3207: b.ORGANIZATION_ID,
3208: b.OPERATION_SEQ_NUM
3209: from wip_job_schedule_interface a,
3210: wip_job_dtls_interface b
3211: where a.source_code = 'MSC'
3212: and a.group_id = G_WIP_GROUP_ID
3213: and a.group_id = b.group_id
3214: and a.header_id = b.parent_header_id

Line 3228: wip_job_dtls_interface b

3224:
3225: Cursor C3 is
3226: select b.rowid
3227: from wip_job_schedule_interface a,
3228: wip_job_dtls_interface b
3229: where a.source_code = 'MSC'
3230: and a.group_id = G_WIP_GROUP_ID
3231: and a.group_id = b.group_id
3232: and a.header_id = b.parent_header_id

Line 3238: from wip_job_dtls_interface c

3234: and b.substitution_type = 3
3235: and b.process_phase = 2
3236: and b.process_status = 1
3237: and b.rowid not in (select min(c.rowid)
3238: from wip_job_dtls_interface c
3239: where b.group_id = c.group_id
3240: and b.parent_header_id = c.parent_header_id
3241: and b.ORGANIZATION_ID = c.ORGANIZATION_ID
3242: and b.INVENTORY_ITEM_ID_OLD = c.INVENTORY_ITEM_ID_OLD

Line 3254: update wip_job_dtls_interface

3250:
3251: For I in C1
3252:
3253: loop
3254: update wip_job_dtls_interface
3255: set operation_Seq_num = I.new_op_seq
3256: where parent_header_id = I.header_id
3257: and operation_seq_num = 1
3258: and load_type = 2

Line 3266: update wip_job_dtls_interface

3262:
3263: For J in C2
3264:
3265: loop
3266: update wip_job_dtls_interface
3267: set QUANTITY_PER_ASSEMBLY = J.qty_per_assy,
3268: REQUIRED_QUANTITY = J.reqd_qty
3269: where group_id = J.group_id
3270: and parent_header_id = J.parent_header_id

Line 3285: delete wip_job_dtls_interface

3281: For K in C3
3282:
3283: loop
3284:
3285: delete wip_job_dtls_interface
3286: where rowid = K.rowid;
3287:
3288: End loop;
3289:

Line 3301: wip_job_dtls_interface jdi,

3297: /* dsr: added outer join in the following cursor*/
3298: cursor cres_upd is select jdi.rowid,jdi.operation_seq_num,
3299: jdi.parent_header_id,rtng.common_routing_Sequence_id
3300: FROM BOM_OPERATIONAL_ROUTINGS rtng,
3301: wip_job_dtls_interface jdi,
3302: wip_job_schedule_interface jsi
3303: where rtng.assembly_item_id (+) = jsi.primary_item_id -- dsr
3304: and jsi.group_id = G_WIP_GROUP_ID
3305: AND rtng.organization_id (+) = jsi.organization_id -- dsr

Line 3503: FROM WIP_JOB_DTLS_INTERFACE jdi

3499: lv_resource_id_old,
3500: lv_ld_type,
3501: lv_scheduled_flag,
3502: lv_parent_id
3503: FROM WIP_JOB_DTLS_INTERFACE jdi
3504: WHERE jdi.group_id= G_WIP_GROUP_ID
3505: AND jdi.parent_header_id= lv_header_id(n)
3506: -- dsr AND jdi.load_type=LT_RESOURCE
3507: AND jdi.load_type IN (LT_RESOURCE, LT_RESOURCE_USAGE

Line 3579: wip_job_dtls_interface jdi,

3575: AND NVL(os.disable_date, lv_start_date(n)) >= lv_start_date(n)
3576: AND not exists(select jdi.operation_seq_num
3577: FROM BOM_OPERATIONAL_ROUTINGS rtng,
3578: BOM_OPERATION_SEQUEnCES seqs,
3579: wip_job_dtls_interface jdi,
3580: wip_job_schedule_interface jsi
3581: where rtng.assembly_item_id= jsi.primary_item_id
3582: AND rtng.organization_id= jsi.organization_id
3583: and nvl(rtng.common_routing_sequence_id,rtng.routing_sequence_id) = os.routing_Sequence_id

Line 3633: wip_job_dtls_interface jdi,

3629: and schedule_flag = 2
3630: AND not exists(select jdi.resource_id_new
3631: FROM BOM_OPERATIONAL_ROUTINGS rtng,
3632: BOM_OPERATION_SEQUENCES seqs,
3633: wip_job_dtls_interface jdi,
3634: wip_job_schedule_interface jsi
3635: where rtng.assembly_item_id= jsi.primary_item_id
3636: AND rtng.organization_id= jsi.organization_id
3637: AND nvl(rtng.common_routing_sequence_id,rtng.routing_sequence_id) = seqs.routing_sequence_id

Line 3706: WIP_JOB_DTLS_INTERFACE JDI

3702: FROM BOM_SUB_OPERATION_RESOURCES bor,
3703: bom_operation_resources bor1,
3704: BOM_OPERATION_SEQUENCES os,
3705: BOM_RESOURCES br,
3706: WIP_JOB_DTLS_INTERFACE JDI
3707: WHERE os.routing_sequence_id= lv_routing_seq_id(n)
3708: AND bor.operation_sequence_id= os.operation_sequence_id
3709: AND os.effectivity_date <= lv_start_date(n)
3710: -- AND NVL(os.disable_date, lv_start_date(n)) >= lv_start_date(n)

Line 3774: UPDATE WIP_JOB_DTLS_INTERFACE

3770: Loop
3771:
3772:
3773:
3774: UPDATE WIP_JOB_DTLS_INTERFACE
3775: SET resource_seq_num= lv_res_seq(j),
3776: resource_id_old = lv_resource_id(j),
3777: schedule_seq_num = lv_sim_res_seq(j),
3778: scheduled_flag = lv_scheduled_flag(j)

Line 3792: substitution, the record in wip_job_dtls_interface should have the

3788: loop through all Resource records where we are implementing alternate and delete the primaries
3789: for that alternate -- this was old logic*/
3790: /* Now if we communicating to WIP that we are passing alternate resource to WIP,
3791: for a resource
3792: substitution, the record in wip_job_dtls_interface should have the
3793: following columns filled in:
3794: load_type = 1
3795: substitution_type = 3
3796: opearation_seq_num, resource_seq_num, resource_id_old, resource_id_new,

Line 3800: alternate resource record will be deleted from wip_job_dtls_interface*/

3796: opearation_seq_num, resource_seq_num, resource_id_old, resource_id_new,
3797: and substitute_group_num should be set to the current(or primary) resource in
3798: wip_operation_resources
3799: replacement_group_num = valid value in wip_sub_operation_resources.Finally the
3800: alternate resource record will be deleted from wip_job_dtls_interface*/
3801:
3802: FOR j IN 1..lsud_res_req_count
3803:
3804: Loop

Line 3807: INSERT INTO WIP_JOB_DTLS_INTERFACE

3803:
3804: Loop
3805: Begin
3806:
3807: INSERT INTO WIP_JOB_DTLS_INTERFACE
3808: ( last_update_date,
3809: last_updated_by,
3810: last_update_login,
3811: creation_date,

Line 3874: delete from WIP_JOB_DTLS_INTERFACE

3870: FROM DUAL;
3871:
3872:
3873: /*Delete the Alternate that we provided */
3874: delete from WIP_JOB_DTLS_INTERFACE
3875: WHERE ROWID= lsud_jdi_rowid(j);
3876: Exception
3877: when others then raise;
3878: End;

Line 3896: from wip_job_dtls_interface

3892:
3893: BEGIN
3894: select nvl(max(operation_seq_num),-1)
3895: into v_previous_op
3896: from wip_job_dtls_interface
3897: where parent_header_id = lv_header_id(n)
3898: and group_id = G_WIP_GROUP_ID
3899: and load_type = 3
3900: and substitution_type <> 1

Line 3905: from wip_job_dtls_interface

3901: and operation_seq_num < luno_op_seq_num(m);
3902:
3903: select nvl(min(operation_seq_num),-1)
3904: into v_next_op
3905: from wip_job_dtls_interface
3906: where parent_header_id = lv_header_id(n)
3907: and group_id = G_WIP_GROUP_ID
3908: and substitution_type <> 1
3909: and load_type = 3

Line 3920: from wip_job_dtls_interface

3916: if (v_previous_op = -1 and v_next_op <> -1) then
3917:
3918: Select first_unit_start_date
3919: into v_last_end
3920: from wip_job_dtls_interface
3921: where parent_header_id = lv_header_id(n)
3922: and group_id = G_WIP_GROUP_ID
3923: and load_type = 3
3924: and operation_seq_num = v_next_op;

Line 3934: from wip_job_dtls_interface

3930: elsif (v_next_op = -1 and v_previous_op <> -1) then
3931:
3932: Select last_unit_completion_date
3933: into v_frst_start
3934: from wip_job_dtls_interface
3935: where parent_header_id = lv_header_id(n)
3936: and group_id = G_WIP_GROUP_ID
3937: and load_type = 3
3938: and operation_seq_num = v_previous_op;

Line 3948: from wip_job_dtls_interface

3944: else
3945:
3946: Select first_unit_start_date
3947: into v_last_end
3948: from wip_job_dtls_interface
3949: where parent_header_id = lv_header_id(n)
3950: and group_id = G_WIP_GROUP_ID
3951: and load_type = 3
3952: and operation_seq_num = v_next_op;

Line 3958: from wip_job_dtls_interface

3954: v_last_start := v_last_end;
3955:
3956: Select last_unit_completion_date
3957: into v_frst_start
3958: from wip_job_dtls_interface
3959: where parent_header_id = lv_header_id(n)
3960: and group_id = G_WIP_GROUP_ID
3961: and load_type = 3
3962: and operation_seq_num = v_previous_op;

Line 3972: INSERT INTO WIP_JOB_DTLS_INTERFACE

3968: EXCEPTION WHEN OTHERS THEN
3969: RAISE;
3970: END;
3971:
3972: INSERT INTO WIP_JOB_DTLS_INTERFACE
3973: ( last_update_date,
3974: last_updated_by,
3975: last_update_login,
3976: creation_date,

Line 4023: from wip_job_dtls_interface

4019:
4020: BEGIN
4021: select max(operation_seq_num)
4022: into v_previous_op
4023: from wip_job_dtls_interface
4024: where parent_header_id = lv_header_id(n)
4025: and group_id = G_WIP_GROUP_ID
4026: and load_type = 3
4027: and substitution_type <> 1

Line 4032: from wip_job_dtls_interface

4028: and operation_seq_num <= lun_op_seq_num(j);
4029:
4030: select min(operation_seq_num)
4031: into v_next_op
4032: from wip_job_dtls_interface
4033: where parent_header_id = lv_header_id(n)
4034: and group_id = G_WIP_GROUP_ID
4035: and substitution_type <> 1
4036: and load_type = 3

Line 4041: from wip_job_dtls_interface s

4037: and operation_seq_num >= lun_op_seq_num(j);
4038:
4039: select nvl(max(resource_seq_num),-1)
4040: into v_previous_res
4041: from wip_job_dtls_interface s
4042: where s.parent_header_id = lv_header_id(n)
4043: and s.group_id = G_WIP_GROUP_ID
4044: and s.load_type = 1
4045: and s.substitution_type <> 1

Line 4052: from wip_job_dtls_interface s

4048:
4049:
4050: select nvl(max(schedule_seq_num),-1)
4051: into v_previous_res1
4052: from wip_job_dtls_interface s
4053: where s.parent_header_id = lv_header_id(n)
4054: and s.group_id = G_WIP_GROUP_ID
4055: and s.load_type = 1
4056: and s.substitution_type <> 1

Line 4063: from wip_job_dtls_interface s

4059:
4060: if (v_previous_res1 > v_previous_res) then
4061: select nvl(max(resource_seq_num),-1)
4062: into v_previous_res
4063: from wip_job_dtls_interface s
4064: where s.parent_header_id = lv_header_id(n)
4065: and s.group_id = G_WIP_GROUP_ID
4066: and s.load_type = 1
4067: and s.substitution_type <> 1

Line 4076: from wip_job_dtls_interface s

4072: end if ;
4073:
4074: select nvl(min(resource_seq_num),-1)
4075: into v_next_res
4076: from wip_job_dtls_interface s
4077: where s.parent_header_id = lv_header_id(n)
4078: and s.group_id = G_WIP_GROUP_ID
4079: and s.substitution_type <> 1
4080: and s.load_type = 1

Line 4086: from wip_job_dtls_interface s

4082: and nvl(s.schedule_seq_num,s.resource_seq_num) > lun_res_seq(j);
4083:
4084: select nvl(min(schedule_seq_num),-1)
4085: into v_next_res1
4086: from wip_job_dtls_interface s
4087: where s.parent_header_id = lv_header_id(n)
4088: and s.group_id = G_WIP_GROUP_ID
4089: and s.substitution_type <> 1
4090: and s.load_type = 1

Line 4097: from wip_job_dtls_interface s

4093:
4094: if ((v_next_res1 < v_next_res) and (v_next_res1 <> -1)) then -- Bug 14051795
4095: select nvl(min(resource_seq_num),-1)
4096: into v_next_res
4097: from wip_job_dtls_interface s
4098: where s.parent_header_id = lv_header_id(n)
4099: and s.group_id = G_WIP_GROUP_ID
4100: and s.substitution_type <> 1
4101: and s.load_type = 1

Line 4116: from wip_job_dtls_interface

4112: -- BUG 14074820, uncommenting the computation of v_last_end
4113:
4114: Select first_unit_start_date
4115: into v_last_end
4116: from wip_job_dtls_interface
4117: where parent_header_id = lv_header_id(n)
4118: and group_id = G_WIP_GROUP_ID
4119: and load_type = 3
4120: and operation_seq_num = v_next_op;

Line 4127: from wip_job_dtls_interface

4123: v_last_start := v_last_end;
4124:
4125: Select last_unit_completion_date
4126: into v_frst_start
4127: from wip_job_dtls_interface
4128: where parent_header_id = lv_header_id(n)
4129: and group_id = G_WIP_GROUP_ID
4130: and load_type = 3
4131: and operation_seq_num = v_previous_op;

Line 4147: from wip_job_dtls_interface

4143: then
4144: -- BUG 14074820, uncommenting the computation of v_last_end
4145: Select start_date
4146: into v_last_end
4147: from wip_job_dtls_interface
4148: where parent_header_id = lv_header_id(n)
4149: and group_id = G_WIP_GROUP_ID
4150: and load_type = 1
4151: and operation_seq_num = v_next_op

Line 4160: from wip_job_dtls_interface

4156: v_last_start := v_last_end;
4157:
4158: Select start_date
4159: into v_frst_start
4160: from wip_job_dtls_interface
4161: where parent_header_id = lv_header_id(n)
4162: and group_id = G_WIP_GROUP_ID
4163: and load_type = 1
4164: and operation_seq_num = v_previous_op

Line 4178: from wip_job_dtls_interface

4174: then
4175: -- BUG 14074820, uncommenting the computation of v_last_end
4176: Select completion_date
4177: into v_last_end
4178: from wip_job_dtls_interface
4179: where parent_header_id = lv_header_id(n)
4180: and group_id = G_WIP_GROUP_ID
4181: and load_type = 1
4182: and operation_seq_num = v_next_op

Line 4191: from wip_job_dtls_interface

4187: v_last_start := v_last_end;
4188:
4189: Select completion_date
4190: into v_frst_start
4191: from wip_job_dtls_interface
4192: where parent_header_id = lv_header_id(n)
4193: and group_id = G_WIP_GROUP_ID
4194: and load_type = 1
4195: and operation_seq_num = v_previous_op

Line 4207: from wip_job_dtls_interface

4203: else
4204: -- BUG 14074820, uncommenting the computation of v_last_end
4205: Select start_date
4206: into v_last_end
4207: from wip_job_dtls_interface
4208: where parent_header_id = lv_header_id(n)
4209: and group_id = G_WIP_GROUP_ID
4210: and load_type = 1
4211: and operation_seq_num = v_next_op

Line 4220: from wip_job_dtls_interface

4216: v_last_start := v_last_end;
4217:
4218: Select completion_date
4219: into v_frst_start
4220: from wip_job_dtls_interface
4221: where parent_header_id = lv_header_id(n)
4222: and group_id = G_WIP_GROUP_ID
4223: and load_type = 1
4224: and operation_seq_num = v_previous_op

Line 4241: INSERT INTO WIP_JOB_DTLS_INTERFACE

4237: END;
4238:
4239: /*insert record for the resource with schedule = no with start and end time
4240: as that of the opertaion*/
4241: INSERT INTO WIP_JOB_DTLS_INTERFACE
4242: ( last_update_date,
4243: last_updated_by,
4244: last_update_login,
4245: creation_date,

Line 4309: WIP_JOB_DTLS_INTERFACE JDI

4305: elsud_jdi_rowid,
4306: elsud_sub_grp,
4307: elsud_rep_grp
4308: FROM WIP_OPERATION_RESOURCES wor,
4309: WIP_JOB_DTLS_INTERFACE JDI
4310: WHERE wor.operation_seq_num = jdi.operation_seq_num
4311: and nvl(wor.schedule_seq_num,wor.resource_seq_num) = jdi.schedule_seq_num
4312: -- and wor.resource_seq_num = jdi.resource_seq_num
4313: and nvl(wor.replacement_group_num,0) = nvl(jdi.replacement_group_num,0)

Line 4331: UPDATE WIP_JOB_DTLS_INTERFACE

4327: FOR x IN 1..lv_elsud_cnt
4328:
4329: Loop
4330:
4331: UPDATE WIP_JOB_DTLS_INTERFACE
4332: SET
4333: -- resource_seq_num= elsud_res_seq(x),
4334: schedule_seq_num = elsud_sim_res_seq(x),
4335: substitute_group_num = elsud_sub_grp(x)

Line 4379: from wip_job_dtls_interface jdi,

4375: lv_res_alt_start_date,
4376: lv_res_alt_completion_date,
4377: lv_res_alt_usage_rate,
4378: lv_res_alt_basis_type
4379: from wip_job_dtls_interface jdi,
4380: wip_operation_resources wor,
4381: wip_sub_operation_resources wsor
4382: where not exists(select 1 from wip_operation_resources wor1
4383: where wor1.operation_seq_num = jdi.operation_seq_num

Line 4412: INSERT INTO WIP_JOB_DTLS_INTERFACE

4408:
4409: Loop
4410: Begin
4411:
4412: INSERT INTO WIP_JOB_DTLS_INTERFACE
4413: ( last_update_date,
4414: last_updated_by,
4415: last_update_login,
4416: creation_date,

Line 4457: delete from WIP_JOB_DTLS_INTERFACE

4453: 1,
4454: 1 --lv_scheduled_flag(j)
4455: FROM DUAL;
4456:
4457: delete from WIP_JOB_DTLS_INTERFACE
4458: WHERE ROWID= lv_res_alt_rowid(j);
4459:
4460: Exception
4461: when others then raise;

Line 4475: UPDATE WIP_JOB_DTLS_INTERFACE set REPLACEMENT_GROUP_NUM = null

4471:
4472: end if;
4473:
4474: --Bug 3333343
4475: UPDATE WIP_JOB_DTLS_INTERFACE set REPLACEMENT_GROUP_NUM = null
4476: where REPLACEMENT_GROUP_NUM = 0
4477: AND GROUP_ID= G_WIP_GROUP_ID
4478: AND PARENT_HEADER_ID= lv_header_id(n)
4479: AND LOAD_TYPE = LT_RESOURCE;

Line 4511: update wip_job_dtls_interface

4507:
4508: v_max_resource_seq := v_max_resource_Seq + 1;
4509:
4510:
4511: update wip_job_dtls_interface
4512: set resource_Seq_num = v_max_resource_Seq
4513: where rowid = i.rowid;
4514: End loop;
4515: */

Line 4671: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

4667: ||' operation_seq_id,'
4668: ||' department_id,'
4669: ||' first_unit_start_date,'
4670: ||' last_unit_completion_date '
4671: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
4672: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
4673: ||' AND nvl(CFM_ROUTING_FLAG,0) <> 3 '
4674: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
4675: ||' AND nvl(operation_seq_num,-1) <> -1'

Line 4732: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

4728: ||' scheduled_flag, '
4729: ||' basis_type, '
4730: ||' department_id, '
4731: ||' FIRM_FLAG '
4732: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
4733: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
4734: ||' AND nvl(CFM_ROUTING_FLAG,0) <> 3 '
4735: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
4736: ||' AND nvl(operation_seq_num,-1) <> -1'

Line 4781: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

4777: ||' operation_seq_num,'
4778: ||' inventory_item_id_old,'
4779: ||' date_required,'
4780: ||' Required_quantity '
4781: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
4782: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
4783: ||' AND nvl(CFM_ROUTING_FLAG,0) <> 3 '
4784: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
4785: ||' AND nvl(operation_seq_num,-1) <> -1'

Line 4834: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

4830: ||' RESOURCE_INSTANCE_ID,'
4831: ||' start_date,'
4832: ||' completion_date, '
4833: ||' SERIAL_NUMBER '
4834: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
4835: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
4836: ||' AND nvl(CFM_ROUTING_FLAG,0) <> 3 '
4837: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
4838: ||' AND nvl(operation_seq_num,-1) <> -1'

Line 4887: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink

4883: ||' RESOURCE_INSTANCE_ID,'
4884: ||' start_date,'
4885: ||' completion_date, '
4886: ||' SERIAL_NUMBER '
4887: ||' FROM MSC_WIP_JOB_DTLS_INTERFACE'||lv_dblink
4888: ||' WHERE SR_INSTANCE_ID= :lv_instance_id'
4889: ||' AND nvl(CFM_ROUTING_FLAG,0) <> 3 '
4890: ||' AND GROUP_ID = :G_WIP_GROUP_ID'
4891: ||' AND nvl(operation_seq_num,-1) <> -1'

Line 4951: eam_material_import b, -- wip_job_dtls_interface b,

4947:
4948: Cursor C1 is
4949: Select a.header_id,min(bos.operation_seq_num) new_op_seq
4950: from eam_work_order_import a, -- wip_job_schedule_interface a,
4951: eam_material_import b, -- wip_job_dtls_interface b,
4952: bom_operation_Sequences bos,
4953: bom_operational_routings bor
4954: where a.group_id = b.group_id
4955: and a.group_id = G_WIP_GROUP_ID

Line 4979: eam_material_import b -- wip_job_dtls_interface b

4975: b.INVENTORY_ITEM_ID, -- b.INVENTORY_ITEM_ID_OLD,
4976: b.ORGANIZATION_ID,
4977: b.OPERATION_SEQ_NUM
4978: from eam_work_order_import a, -- wip_job_schedule_interface a,
4979: eam_material_import b -- wip_job_dtls_interface b
4980: where a.source_code = 'MSC'
4981: and a.group_id = G_WIP_GROUP_ID
4982: and a.group_id = b.group_id
4983: -- and a.header_id = b.parent_header_id

Line 4998: eam_material_import b -- wip_job_dtls_interface b

4994:
4995: Cursor C3 is
4996: select b.rowid
4997: from eam_work_order_import a, -- wip_job_schedule_interface a,
4998: eam_material_import b -- wip_job_dtls_interface b
4999: where a.source_code = 'MSC'
5000: and a.group_id = G_WIP_GROUP_ID
5001: and a.group_id = b.group_id
5002: -- and a.header_id = b.parent_header_id

Line 5009: from eam_material_import c -- wip_job_dtls_interface c

5005: -- and b.substitution_type = 3
5006: -- and b.process_phase = 2
5007: -- and b.process_status = 1
5008: and b.rowid not in (select min(c.rowid)
5009: from eam_material_import c -- wip_job_dtls_interface c
5010: where b.group_id = c.group_id
5011: -- and b.parent_header_id = c.parent_header_id
5012: and b.wip_entity_id = c.wip_entity_id
5013: and b.ORGANIZATION_ID = c.ORGANIZATION_ID

Line 5031: update eam_material_import -- wip_job_dtls_interface

5027:
5028: For I in C1
5029:
5030: loop
5031: update eam_material_import -- wip_job_dtls_interface
5032: set operation_Seq_num = I.new_op_seq
5033: -- where parent_header_id = I.header_id
5034: where wip_entity_id = I.header_id
5035: and operation_seq_num = 1

Line 5046: update eam_material_import -- wip_job_dtls_interface

5042:
5043: For J in C2
5044:
5045: loop
5046: update eam_material_import -- wip_job_dtls_interface
5047: set QUANTITY_PER_ASSEMBLY = J.qty_per_assy,
5048: REQUIRED_QUANTITY = J.reqd_qty
5049: where group_id = J.group_id
5050: -- and parent_header_id = J.parent_header_id

Line 5069: -- delete wip_job_dtls_interface

5065:
5066: loop
5067:
5068: --jguo
5069: -- delete wip_job_dtls_interface
5070: -- where rowid = K.rowid;
5071:
5072: null;
5073: