179: ,batch_status
180: ,batch_id
181: ,NVL(formula_id,0)
182: ,NVL(routing_id,0)
183: FROM gme_batch_header b,
184: gem_lookups lkup
185: WHERE organization_id = p_org_id
186: AND batch_type= 0
187: AND batch_status in (1,2)
206: ,batch_status
207: ,batch_id
208: ,NVL(formula_id,0)
209: ,NVL(routing_id,0)
210: FROM gme_batch_header b,
211: gem_lookups lkup
212: WHERE organization_id = p_org_id
213: AND batch_type= 0
214: AND batch_status = 2
232: ,batch_status
233: ,batch_id
234: ,NVL(formula_id,0)
235: ,NVL(routing_id,0)
236: FROM gme_batch_header b,
237: gem_lookups lkup
238: WHERE organization_id = p_org_id
239: AND batch_type= 0
240: AND batch_status in (2,3)
258: ,batch_status
259: ,batch_id
260: ,NVL(formula_id,0)
261: ,NVL(routing_id,0)
262: FROM gme_batch_header b,
263: gem_lookups lkup
264: WHERE organization_id = p_org_id
265: AND batch_type= 0
266: AND batch_status in (2,3)
285: ,batch_status
286: ,batch_id
287: ,NVL(formula_id,0)
288: ,NVL(routing_id,0)
289: FROM gme_batch_header b,
290: gem_lookups lkup
291: WHERE organization_id = p_org_id
292: AND batch_type= 0
293: AND batch_status in (2,3)
317: ,batch_status
318: ,batch_id
319: ,NVL(formula_id,0)
320: ,NVL(routing_id,0)
321: FROM gme_batch_header h,
322: gem_lookups lkup
323: WHERE organization_id = p_org_id
324: AND batch_type= 0
325: AND batch_status = 3
350: ,batch_status
351: ,batch_id
352: ,NVL(formula_id,0)
353: ,NVL(routing_id,0)
354: FROM gme_batch_header b,
355: gem_lookups lkup
356: WHERE organization_id = p_org_id
357: AND batch_type= 0
358: AND batch_status in (1,2)
1128: BEGIN
1129: OPEN x_activity_cursor FOR
1130: SELECT a.activity,
1131: a.batchstep_activity_id
1132: FROM gme_batch_header h,
1133: gme_batch_steps s,
1134: gme_batch_step_activities a
1135: WHERE h.organization_id = p_organization_id
1136: AND h.batch_id = p_batch_id
1178:
1179: OPEN x_resource_cursor FOR
1180: SELECT r.resources,
1181: r.batchstep_resource_id
1182: FROM gme_batch_header h,
1183: gme_batch_steps s,
1184: gme_batch_step_activities a,
1185: gme_batch_step_resources r
1186: WHERE h.organization_id = p_org_id
2180: OPEN x_step_cursor FOR
2181: SELECT s.batchstep_no,
2182: o.oprn_desc,
2183: s.batchstep_id
2184: FROM gme_batch_header h,
2185: gme_batch_steps s,
2186: gmd_operations o
2187: WHERE h.batch_id = p_batch_id
2188: AND h.batch_type = 0
2195: UNION
2196: SELECT s.batchstep_no,
2197: o.oprn_desc,
2198: s.batchstep_id
2199: FROM gme_batch_header h,
2200: gme_batch_steps s,
2201: gmd_operations o
2202: WHERE h.batch_id = p_batch_id
2203: AND h.batch_type = 0
3603: OPEN x_line_type_cursor FOR
3604: SELECT distinct decode(d.line_type,-1,'1',+1,'2',+2,'3'),
3605: meaning,
3606: d.line_type
3607: FROM gme_batch_header h,
3608: gme_material_details d,
3609: gme_batch_step_items si,
3610: gme_batch_steps s,
3611: gem_lookups lkup
3630: OPEN x_line_type_cursor FOR
3631: SELECT distinct decode(d.line_type,-1,'1',+1,'2',+2,'3'),
3632: meaning,
3633: d.line_type
3634: FROM gme_batch_header h,
3635: gme_material_details d,
3636: gem_lookups lkup
3637: WHERE h.organization_id = p_organization_id
3638: AND h.batch_id = p_batch_id
3697: OPEN x_line_type_cursor FOR
3698: SELECT distinct decode(d.line_type,-1,'1',+1,'2',+2,'3'),
3699: meaning,
3700: d.line_type
3701: FROM gme_batch_header h,
3702: gme_material_details d,
3703: gme_batch_step_items si,
3704: gme_batch_steps s,
3705: gem_lookups lkup
3725: OPEN x_line_type_cursor FOR
3726: SELECT distinct decode(d.line_type,-1,'1',+1,'2',+2,'3'),
3727: meaning,
3728: d.line_type
3729: FROM gme_batch_header h,
3730: gme_material_details d,
3731: gem_lookups lkup
3732: WHERE h.organization_id = p_organization_id
3733: AND h.batch_id = p_batch_id
3923: TO_NUMBER(NULL) act_step_qty, gbs.step_qty_um,
3924: TO_CHAR(gbs.plan_start_date, p_date_format||gme_mobile_txn.HOUR_MIN_SEC_FORMAT_STRING),
3925: ' ' act_start_date,
3926: TO_CHAR(gbs.plan_start_date, p_date_format||gme_mobile_txn.HOUR_MIN_SEC_FORMAT_STRING) plan_comlt_date
3927: FROM gme_batch_header gbh, gme_batch_steps gbs, gmd_operations gmo, gem_lookups glk
3928: WHERE gbh.batch_id = p_batch_id
3929: AND gbh.batch_type = 0
3930: AND gbh.batch_id = gbs.batch_id
3931: AND gbs.step_status = 1
3954: TO_NUMBER(NULL) act_step_qty, gbs.step_qty_um,
3955: TO_CHAR(gbs.plan_start_date, p_date_format||gme_mobile_txn.HOUR_MIN_SEC_FORMAT_STRING),
3956: DECODE(gbs.actual_start_date,NULL,' ',TO_CHAR(gbs.actual_start_date, p_date_format||gme_mobile_txn.HOUR_MIN_SEC_FORMAT_STRING)) act_start_date,
3957: TO_CHAR(gbs.plan_start_date, p_date_format||gme_mobile_txn.HOUR_MIN_SEC_FORMAT_STRING) plan_comlt_date
3958: FROM gme_batch_header gbh, gme_batch_steps gbs, gmd_operations gmo, gem_lookups glk
3959: WHERE gbh.batch_id = p_batch_id
3960: AND gbh.batch_type = 0
3961: AND gbh.batch_id = gbs.batch_id
3962: AND gbs.step_status IN (1,2)
3995: , ROUND(DECODE(s.step_status, 2, r.plan_rsrc_qty, 3, r.actual_rsrc_qty),2)
3996: , r.resource_qty_um
3997: , ROUND(DECODE(s.step_status, 2, r.plan_rsrc_usage, 3, r.actual_rsrc_usage),2)
3998: , r.usage_um
3999: FROM gme_batch_header h,
4000: gme_batch_steps s,
4001: gme_batch_step_activities a,
4002: gme_batch_step_resources r,
4003: gmp_resource_instances i,