DBA Data[Home] [Help]

APPS.CSD_UPDATE_PROGRAMS_PVT dependencies on CSD_REPAIR_JOB_XREF

Line 129: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,

125: );
126:
127: TYPE JOB_COMPLETION_Rec_Type IS RECORD
128: (
129: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,
131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,
133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,

Line 130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,

126:
127: TYPE JOB_COMPLETION_Rec_Type IS RECORD
128: (
129: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,
131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,
133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
134: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,

Line 131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,

127: TYPE JOB_COMPLETION_Rec_Type IS RECORD
128: (
129: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,
131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,
133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
134: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
135: repair_number CSD_REPAIRS.repair_number%type,

Line 132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,

128: (
129: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,
131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,
133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
134: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
135: repair_number CSD_REPAIRS.repair_number%type,
136: promise_date CSD_REPAIRS.promise_date%type,

Line 133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,

129: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,
131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,
133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
134: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
135: repair_number CSD_REPAIRS.repair_number%type,
136: promise_date CSD_REPAIRS.promise_date%type,
137: ro_serial_num CSD_REPAIRS.serial_number%type ,

Line 134: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,

130: wip_entity_id CSD_REPAIR_JOB_XREF.wip_entity_id%type,
131: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
132: allocated_comp_qty CSD_REPAIR_JOB_XREF.quantity_completed%type ,
133: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
134: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
135: repair_number CSD_REPAIRS.repair_number%type,
136: promise_date CSD_REPAIRS.promise_date%type,
137: ro_serial_num CSD_REPAIRS.serial_number%type ,
138: ro_item_id CSD_REPAIRS.inventory_item_id%type ,

Line 150: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,

146: );
147:
148: TYPE JOB_CREATION_Rec_Type IS RECORD
149: (
150: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
151: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
152: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
153: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
154: wip_entity_id WIP_ENTITIES.wip_entity_id%type,

Line 151: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,

147:
148: TYPE JOB_CREATION_Rec_Type IS RECORD
149: (
150: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
151: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
152: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
153: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
154: wip_entity_id WIP_ENTITIES.wip_entity_id%type,
155: wip_entity_name WIP_ENTITIES.wip_entity_name%type,

Line 152: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,

148: TYPE JOB_CREATION_Rec_Type IS RECORD
149: (
150: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
151: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
152: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
153: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
154: wip_entity_id WIP_ENTITIES.wip_entity_id%type,
155: wip_entity_name WIP_ENTITIES.wip_entity_name%type,
156: job_qty WIP_DISCRETE_JOBS.start_quantity%type ,

Line 153: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,

149: (
150: repair_job_xref_id CSD_REPAIR_JOB_XREF.repair_job_xref_id%type,
151: repair_line_id CSD_REPAIR_JOB_XREF.repair_line_id%type,
152: organization_id CSD_REPAIR_JOB_XREF.organization_id%type,
153: allocated_job_qty CSD_REPAIR_JOB_XREF.quantity%type ,
154: wip_entity_id WIP_ENTITIES.wip_entity_id%type,
155: wip_entity_name WIP_ENTITIES.wip_entity_name%type,
156: job_qty WIP_DISCRETE_JOBS.start_quantity%type ,
157: creation_date WIP_DISCRETE_JOBS.creation_date%type

Line 722: -- This cursor gets all the records in csd_repair_job_xref for which

718:
719: -- User defined exception
720: SKIP_RECORD EXCEPTION;
721:
722: -- This cursor gets all the records in csd_repair_job_xref for which
723: -- the completed qty is less than the allocated
724: -- for the given repair line id, 11/9/04: Vijay
725: Cursor REPAIR_JOBS( p_rep_line_id in number )IS
726: SELECT

Line 743: from CSD_REPAIR_JOB_XREF crj,

739: wdj.date_completed,
740: wdj.primary_item_id job_item_id,
741: we.wip_entity_name,
742: mtl.serial_number_control_code
743: from CSD_REPAIR_JOB_XREF crj,
744: CSD_REPAIRS cra,
745: WIP_DISCRETE_JOBS wdj,
746: WIP_ENTITIES we,
747: MTL_SYSTEM_ITEMS mtl

Line 758: -- This cursor gets all the records in csd_repair_job_xref for which

754: and cra.repair_line_id = p_rep_line_id
755: and nvl(wdj.quantity_completed,0) > 0
756: order by crj.wip_entity_id, cra.promise_date;
757:
758: -- This cursor gets all the records in csd_repair_job_xref for which
759: -- the completed qty is less than the allocated
760: -- all records irrespective of rep_line_id 11/9/04: Vijay
761: Cursor REPAIR_JOBS_ALL IS
762: SELECT

Line 779: from CSD_REPAIR_JOB_XREF crj,

775: wdj.date_completed,
776: wdj.primary_item_id job_item_id,
777: we.wip_entity_name,
778: mtl.serial_number_control_code
779: from CSD_REPAIR_JOB_XREF crj,
780: CSD_REPAIRS cra,
781: WIP_DISCRETE_JOBS wdj,
782: WIP_ENTITIES we,
783: MTL_SYSTEM_ITEMS mtl

Line 875: --Get the sum of completed quantity from csd_repair_job_xref

871: Debug('repair_line_id ='||TO_CHAR(job.repair_line_id),l_mod_name,1);
872: Debug('quantity_completed ='||TO_CHAR(job.job_completed_qty),l_mod_name,1);
873: Debug('quantity ='||TO_CHAR(job.job_qty),l_mod_name,1);
874:
875: --Get the sum of completed quantity from csd_repair_job_xref
876: select nvl(sum(quantity_completed),0), count(repair_line_id) ---Added by vijay
877: into l_completed_qty, l_ro_count ----------------------------to put ro count in JC event
878: from csd_repair_job_xref
879: where wip_entity_id = JOB.wip_entity_id;

Line 878: from csd_repair_job_xref

874:
875: --Get the sum of completed quantity from csd_repair_job_xref
876: select nvl(sum(quantity_completed),0), count(repair_line_id) ---Added by vijay
877: into l_completed_qty, l_ro_count ----------------------------to put ro count in JC event
878: from csd_repair_job_xref
879: where wip_entity_id = JOB.wip_entity_id;
880:
881: l_ro_count := nvl(l_ro_Count,0); --Added by vijay to put ro count in JC event
882:

Line 955: -- Update csd_repair_job_xref with qty completed

951: and mt.transaction_action_id = 31 -- Wip Assembly Completion
952: and mut.serial_number = JOB.ro_serial_num
953: and mt.inventory_item_id = JOB.ro_item_id;
954:
955: -- Update csd_repair_job_xref with qty completed
956: update csd_repair_job_xref
957: set quantity_completed = nvl(quantity_completed,0) + 1,
958: object_version_number = object_version_number+1,
959: last_update_date = sysdate,

Line 956: update csd_repair_job_xref

952: and mut.serial_number = JOB.ro_serial_num
953: and mt.inventory_item_id = JOB.ro_item_id;
954:
955: -- Update csd_repair_job_xref with qty completed
956: update csd_repair_job_xref
957: set quantity_completed = nvl(quantity_completed,0) + 1,
958: object_version_number = object_version_number+1,
959: last_update_date = sysdate,
960: last_updated_by = fnd_global.user_id,

Line 1066: csd_repair_job_xref crj

1062: and mt.transaction_source_type_id = 5 -- Job or Schedule
1063: and mt.transaction_action_id = 31 -- Wip Assembly Completion
1064: and mut.serial_number not in (select crh.paramc3
1065: from csd_repair_history crh,
1066: csd_repair_job_xref crj
1067: where crh.repair_line_id = crj.repair_line_id
1068: and crj.wip_entity_id = JOB.wip_entity_id
1069: and crh.event_code = 'JC')
1070: and mut.serial_number not in (Select cra.serial_number

Line 1072: csd_repair_job_xref crj

1068: and crj.wip_entity_id = JOB.wip_entity_id
1069: and crh.event_code = 'JC')
1070: and mut.serial_number not in (Select cra.serial_number
1071: from csd_repairs cra,
1072: csd_repair_job_xref crj
1073: where cra.repair_line_id = crj.repair_line_id
1074: and crj.wip_entity_id = JOB.wip_entity_id
1075: and cra.serial_number is not null)
1076: and rownum = 1;

Line 1078: -- Update csd_repair_job_xref with qty completed

1074: and crj.wip_entity_id = JOB.wip_entity_id
1075: and cra.serial_number is not null)
1076: and rownum = 1;
1077:
1078: -- Update csd_repair_job_xref with qty completed
1079: update csd_repair_job_xref
1080: set quantity_completed = nvl(quantity_completed,0) + 1,
1081: object_version_number = object_version_number+1,
1082: last_update_date = sysdate,

Line 1079: update csd_repair_job_xref

1075: and cra.serial_number is not null)
1076: and rownum = 1;
1077:
1078: -- Update csd_repair_job_xref with qty completed
1079: update csd_repair_job_xref
1080: set quantity_completed = nvl(quantity_completed,0) + 1,
1081: object_version_number = object_version_number+1,
1082: last_update_date = sysdate,
1083: last_updated_by = fnd_global.user_id,

Line 1204: csd_repair_job_xref crj

1200: and mt.transaction_source_type_id = 5 -- Job or Schedule
1201: and mt.transaction_action_id = 31 -- Wip Assembly Completion
1202: and mut.serial_number not in (select crh.paramc3
1203: from csd_repair_history crh,
1204: csd_repair_job_xref crj
1205: where crh.repair_line_id = crj.repair_line_id
1206: and crj.wip_entity_id = JOB.wip_entity_id
1207: and crh.event_code = 'JC')
1208: and rownum = 1;

Line 1210: -- Update csd_repair_job_xref with qty completed

1206: and crj.wip_entity_id = JOB.wip_entity_id
1207: and crh.event_code = 'JC')
1208: and rownum = 1;
1209:
1210: -- Update csd_repair_job_xref with qty completed
1211: update csd_repair_job_xref
1212: set quantity_completed = nvl(quantity_completed,0) + 1,
1213: object_version_number = object_version_number+1,
1214: last_update_date = sysdate,

Line 1211: update csd_repair_job_xref

1207: and crh.event_code = 'JC')
1208: and rownum = 1;
1209:
1210: -- Update csd_repair_job_xref with qty completed
1211: update csd_repair_job_xref
1212: set quantity_completed = nvl(quantity_completed,0) + 1,
1213: object_version_number = object_version_number+1,
1214: last_update_date = sysdate,
1215: last_updated_by = fnd_global.user_id,

Line 1327: -- Update csd_repair_job_xref with qty completed

1323: -- Debug messages
1324: Debug('l_update_Qty ='||TO_CHAR(l_update_Qty),l_mod_name,1);
1325: Debug('l_remaining_qty ='||TO_CHAR(l_remaining_qty),l_mod_name,1);
1326:
1327: -- Update csd_repair_job_xref with qty completed
1328: update csd_repair_job_xref
1329: set quantity_completed = nvl(quantity_completed,0) + NVL(l_update_qty,0),
1330: object_version_number = object_version_number+1,
1331: last_update_date = sysdate,

Line 1328: update csd_repair_job_xref

1324: Debug('l_update_Qty ='||TO_CHAR(l_update_Qty),l_mod_name,1);
1325: Debug('l_remaining_qty ='||TO_CHAR(l_remaining_qty),l_mod_name,1);
1326:
1327: -- Update csd_repair_job_xref with qty completed
1328: update csd_repair_job_xref
1329: set quantity_completed = nvl(quantity_completed,0) + NVL(l_update_qty,0),
1330: object_version_number = object_version_number+1,
1331: last_update_date = sysdate,
1332: last_updated_by = fnd_global.user_id,

Line 1550: -- This cursor gets all the records in csd_repair_job_xref

1546: -- Variable used in FND log
1547: l_error_level number := FND_LOG.LEVEL_ERROR;
1548: l_mod_name varchar2(2000) := 'csd.plsql.csd_update_programs_pvt.job_creation_update';
1549:
1550: -- This cursor gets all the records in csd_repair_job_xref
1551: -- that does not have wip_entity_id.
1552: --Cursor split into two to remove OR condition
1553: -- Vijay 11/9/04
1554: Cursor JOB_CREATION( p_rep_line_id in number )IS

Line 1564: from CSD_REPAIR_JOB_XREF crj,

1560: we.wip_entity_id,
1561: we.wip_entity_name,
1562: wdj.start_quantity job_qty,
1563: wdj.creation_date
1564: from CSD_REPAIR_JOB_XREF crj,
1565: WIP_ENTITIES we,
1566: wip_discrete_jobs wdj
1567: where wdj.wip_entity_id = we.wip_entity_id
1568: and crj.job_name = we.wip_entity_name

Line 1572: -- This cursor gets all the records in csd_repair_job_xref

1568: and crj.job_name = we.wip_entity_name
1569: and crj.organization_id = we.organization_id
1570: and crj.repair_line_id = p_rep_line_id
1571: and crj.wip_entity_id is null;
1572: -- This cursor gets all the records in csd_repair_job_xref
1573: -- that does not have wip_entity_id.
1574: Cursor JOB_CREATION_ALL IS
1575: SELECT
1576: crj.repair_job_xref_id,

Line 1584: from CSD_REPAIR_JOB_XREF crj,

1580: we.wip_entity_id,
1581: we.wip_entity_name,
1582: wdj.start_quantity job_qty,
1583: wdj.creation_date
1584: from CSD_REPAIR_JOB_XREF crj,
1585: WIP_ENTITIES we,
1586: wip_discrete_jobs wdj
1587: where wdj.wip_entity_id = we.wip_entity_id
1588: and crj.job_name = we.wip_entity_name

Line 1621: -- When Jobs are created from the UI, a record is inserted in csd_repair_job_xref

1617: -- Keeping the running total of the records
1618: -- for commiting purpose
1619: l_count := 0;
1620:
1621: -- When Jobs are created from the UI, a record is inserted in csd_repair_job_xref
1622: -- with the job name. Once the WIP Job is created in wip_discrete_jobs
1623: -- then the update program will find the wip_entity_id and update it.
1624: -- Also it updates the quantity_in_wip in the csd_repairs with Job start quantity
1625: --

Line 1627: -- CSD_REPAIR_JOB_XREF

1623: -- then the update program will find the wip_entity_id and update it.
1624: -- Also it updates the quantity_in_wip in the csd_repairs with Job start quantity
1625: --
1626: -- When the WIP Job is submitted from the UI, the record would look as follows:
1627: -- CSD_REPAIR_JOB_XREF
1628: -- Repair Job Repair Order Allocated Qty Job Name Job Qty Wip_entity_ID
1629: -- RJ1 R1 1 JOB1 3
1630: -- RJ2 R2 1 JOB1 3
1631: -- RJ3 R3 1 JOB1 3

Line 1634: -- CSD_REPAIR_JOB_XREF

1630: -- RJ2 R2 1 JOB1 3
1631: -- RJ3 R3 1 JOB1 3
1632: --
1633: -- After Running the Update Program the record would look as follows:
1634: -- CSD_REPAIR_JOB_XREF
1635: -- Repair Job Repair Order Allocated Qty Job Name Job Qty Wip_entity_ID
1636: -- RJ1 R1 1 JOB1 3 1121
1637: -- RJ2 R2 1 JOB1 3 1121
1638: -- RJ3 R3 1 JOB1 3 1121

Line 1702: -- Updating csd_repair_job_xref with the wip_entity_id

1698: Debug('LOG_ACTIVITY api failed ',l_mod_name,4);
1699: RAISE FND_API.G_EXC_ERROR;
1700: END IF;
1701:
1702: -- Updating csd_repair_job_xref with the wip_entity_id
1703: Update csd_repair_job_xref
1704: set wip_entity_id = K.wip_entity_id,
1705: object_version_number = object_version_number+1,
1706: last_update_date = sysdate,

Line 1703: Update csd_repair_job_xref

1699: RAISE FND_API.G_EXC_ERROR;
1700: END IF;
1701:
1702: -- Updating csd_repair_job_xref with the wip_entity_id
1703: Update csd_repair_job_xref
1704: set wip_entity_id = K.wip_entity_id,
1705: object_version_number = object_version_number+1,
1706: last_update_date = sysdate,
1707: last_updated_by = fnd_global.user_id,